1.error: failed to push some refs to 'https://github.com/xx.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
緣由:遠程分支和本地分支不同,這樣一種操做最會出現,萌新的時候,在github建立了一個倉庫,也順利clone到了本地
但由於任性刪除了遠程分支的master也就是強制刪除了倉庫,當你再建立一個項目準備把本地項目提交上去的時候就會出現這種狀況
解決拌飯:
第一種
git fetch
git rebase
第二種
確保遠程倉庫沒有你要的文件, git push origin master -f(強制覆蓋遠程倉庫的文件)git