主要是這篇博客進行一些補充。
第一步照做就行
首先是第二步 克隆倉庫到本地
先下載一個git,電腦創建一個新文件夾,然后
git clone xxxxx
注意即使你使用了代理,這里大概率也會報錯,Failed to connect to github.com
port 443 after 21059 ms: Could not connect to server
解決方法就是-配置 Git 使用代理
git config --global http.proxy http://127.0.0.1:你的代理端口
git config --global https.proxy https://127.0.0.1:你的代理端口
關于第三步 其實有官方文檔
這里的2這里如果你不能save,你可以先切換,然后換回來就可以save了。save后,多刷新幾次,出現3這個頁面就成果了
第四步
提交更改
git commit -am 'init'
git push
這里你可能又會遇到一些問題Author identity unknown …fatal: unable to auto-detect email address (got ‘Administrator@SKY-20240903MZX.(none)’)
錯誤是因為 Git 需要知道你是誰(提交者的身份),才能讓你提交代碼。你需要先配置你的用戶名和郵箱地址。
git config --global user.name "xxx"
git config --global user.email "your-email@example.com"
然后再次提交即可