1. 先在本地电脑按照Git:Git - Downloads
2. 在GitHub上面新建一个自己的Repository
3. 打开本地项目的位置,打开该路径下cmd终端
4. git config --global user.name "oner0916"
5. git config --global user.email "1064035379@qq.com"
6. git init
7. git add .
8. git commit -m "mycode"
9. git remote add origin https://....(GitHub上面的http地址)
10. git push -u origin main(上传到main分支)
这一步可能报错,解决:git config --global http.sslVerify "false"
11. 如果出现报错:
! [rejected] main -> main (non-fast-forward)
error: failed to push some refs to 'https://github.com/oner0916/A-hybrid-CNN-BiLSTM-network-for-automatic-sleep-staging-based-on-two-channel-EEG-signals.git'
12. git pull
13. git push -u origin main
14. git push -f origin main (-f 强制执行)
上传完成!