Git-往返github和本地
將GitHub倉庫Test弄到本地
- 本地新建文件夾Test
- 右擊運行gitbash
- 在gitbash中輸入git init
- 在github 倉庫選擇clone or download
- 複製連接https://github.com/xxx/xxx.git
- 在gitbash中輸入git clone https://github.com/xxx/xxx.git
將本地文件夾上傳到GitHub
- github中新建倉庫NewRepo
- 在本地文件夾Test中右擊選擇gitbash,輸入git init
- git status(無關緊要)
- git add *
git status(無關緊要)
- git commit -m 'description of this commit'
- git status(無關緊要)
- 從github倉庫NewRepo點擊clone or download,複製連接
- git remote add origin https://github.com/xxx/xxx.git
- git push -u origin master
歡迎關注本站公眾號,獲取更多信息