git pull:无法分离Unicode文件名的头
我运行这个git pull命令,它会阻塞Unicode文件名git pull:无法分离Unicode文件名的头,git,unicode,osx-leopard,Git,Unicode,Osx Leopard,我运行这个git pull命令,它会阻塞Unicode文件名 & git pull From . * branch master -> FETCH_HEAD First, rewinding head to replay your work on top of it... error: The following untracked working tree files would be overwritten by checkout:
& git pull
From .
* branch master -> FETCH_HEAD
First, rewinding head to replay your work on top of it...
error: The following untracked working tree files would be overwritten by checkout:
test-sample-files/MByte/CJK-UTF8-MultiByte/樣品套裝/サンプル.java
test-sample-files/MByte/CJK-UTF8-MultiByte/樣品套裝/의 견본을 뽑다.java
test-sample-files/MByte/japanese/これはサンプルのテストであり、できるだけ早く修正する必要があります.java
test-sample-files/MByte/japanese/サンプル.java
test-sample-files/MByte/korean/의 견본을 뽑다.java
Please move or remove them before you can switch branches.
Aborting
could not detach HEAD
但是,git状态会报告工作目录是否干净
$ git status
# On branch dev/experimental
# Your branch and 'master' have diverged,
# and have 3 and 96 different commit(s) each, respectively.
#
nothing to commit (working directory clean)
没有“git add”、“git reset”或“rm…*”可以解决这种情况。非常感谢您的帮助
备注:我正在Mac OS X Leopard(10.5)上运行“git version 1.7.5.4”,这是我为Leopard找到的最新预构建版本。您的文件在工作树的当前状态下未被跟踪。这就是为什么
gitadd
或gitrm
什么都不做的原因
使用git Stash save将它们隐藏起来--未跟踪的,它们将被保存在一个隐藏中。拉取后,您可以使用git stash pop
进行恢复,但可能会发生冲突,因为拉取将在可能的不同内容处签出主题
由于您一直使用Git 1.7.5stash
不知道--untracked
选项,因此您可以
- 将未跟踪的文件移动到临时目录,并将其还原:
git ls-files --other --exclude-standard | xargs -t -I file mv file untracked
- 或者使用git add-u添加它们,然后提交