Please commit your changes or stash them before you merge. Aborting
Please commit your changes or stash them before you merge.
Aborting
出现这种情况的原因:git pull 是发现本地的修改的代码和远程仓库的不一个版本,解决这种有两个办法
-
将本地修改的代码放到堆栈中
-
git stash
-
git pull
-
git stash pop
接下来diff一下此文件看看自动合并的情况,并作出相应修改。
-
-
放弃本地修改,直接覆盖之
git reset --hard
git pull