no branch 问题

现象如下:

lynn.feng:~/project/Git/M_MT6737_MP$ git branch -a
* (no branch)
a36_panasonic_l004
b36_panasonic_tmp
master

lynn.feng:~/project/Git/M_MT6737_MP$ git checkout master
kernel-3.18/drivers/input/touchscreen/mediatek/GT9XX_B36/gt9xx_driver.c: needs merge
error: you need to resolve your current index first

lynn.feng:~/project/Git/M_MT6737_MP$ git status
# Not currently on any branch.

该问题已经说的很明白了,有文件没有提交,所以git树无法统一,解决方法如下:

git reset --merge 

上一篇:关于Android App开发技术分类的一个小总结


下一篇:spring声明式事务 同一类内方法调用事务失效(转)