我试图pull origin a
。如何忽略已经在git中跟踪的文件
去以下:
error: Your local changes to the following files would be overwritten by merge:
src/.cproject
src/.project
src/navigate/navigate_main.c
Please, commit your changes or stash them before you can merge.
Aborting
git的状态显示:
modified: .gitignore
modified: src/.cproject
modified: src/.project
modified: src/navigate/navigate_main.c
我做git rm --cached src/.project
前3,和stashed
第四
我再次拉和unstashed我变化。
但是当我做pull origin a
我得到:
M .gitignore
U src/.cproject
M src/navigate/navigate_main.c
Pull is not possible because you have unmerged files.
Please, fix them up in the work tree, and then use 'git add/rm <file>'
as appropriate to mark resolution, or use 'git commit -a'.
如何清洁这种一劳永逸?
您修改了文件,这些文件与服务器上的文件不同。首先合并这些文件。然后提交。然后拉。 –