git合并出现冲突:Your local changes to the following files would be overwritten by merge:Please, commit your changes or stash them before you can merge.解决方案:git stash //使返回到自己上一个commit,先隐藏git pull origin master //拉取最新的代码git stash pop //回到自己修改的代码 git pull每次都
小明在愉快的敲代码 vim ok 他在ok里敲了simachanping git commit -am "commit first version by xiaoming" 然后这时他接到了产品的电话,说有一个新需求要做名字是iss53,小明就打算新建一个iss53分支来实现需求 git checkout -b iss53 vim ok 他在ok里面敲了simaceshi git commit -am "solve iss53 ing" 现在在iss53分支里ok
假设冲突文件是 test/TestCase.php 下面分5种情况讨论. 1.本地不变. 然后远程别人有更新. git pull 这种最简单,没有冲突,本地工作区直接更新 2.我本地修改,但是不add. 然后远程别人有更新,此时 : git pull, git会告诉你: error: Your local changes to the following files would be overwritten by merge: tests/TestCa