我真的不明白git那麼好,我開始反感甚至試圖使用它。git - 由於合併衝突而陷入無休止的推/拉循環
我試圖把我的項目的一個新版本,以我的遠程存儲庫(git push origin master
),但是當我做,我得到的消息:
Error: failed to push some refs to 'myRepo'. Updates where rejected because the tip of your current branch is behind its remote counterpart. Integrate the remote changes (e.g. git pull ...) before pushing again.
所以我儘量拉(git pull origin master
)然後我得到以下錯誤:
Error: The following untracked working tree files would be overwritten by merge: <bunch of image files and a few PHP files>
什麼我錯在這裏做的,用簡單的英語(以及一些混帳的幫我解決這個問題)?
令人驚訝的是,我明白了。我可以看到發生了分歧:「你的分支和'起源/主''分開了,分別有5個不同的提交。我會用什麼命令「將未跟蹤的文件移開」? – ReactingToAngularVues
是否要將它們移動到其他位置(到臨時目錄)或刪除它們? – janos
絕對臨時目錄。我做了一些備份,以防事情變壞。 – ReactingToAngularVues