我已经设置了
git config --global core.filemode false
使用git config -l
...
core.repositoryformatversion=0
core.filemode=false
core.bare=false
core.logallrefupdates=true
core.ignorecase=true
core.autocrlf=false
...
但是当我输入git diff foo
时,我得到了这个:
diff --git a/.gitignore b/.gitignore
old mode 100755
new mode 100644
diff --git a/Makefile b/Makefile
old mode 100755
new mode 100644
diff --git a/config.ini b/config.ini
old mode 100755
new mode 100644
...
我在我的内部导入了一个远程存储库:
git remote add foo //192.168.1.42/foo/
git pull foo master
git checkout -b foo foo/master
git diff master
我的错误在哪里?
答案 0 :(得分:9)
确保您没有该设置的多个条目,并将其设置为本地而非全局:
git config --global --unset-all core.filemode
git config --unset-all core.filemode
git config core.filemode false