ewok ewok - 1 month ago 9
Git Question

git: global configs not getting used in repositories

I have set a couple global configs in git:

git config --global core.autocrlf true
git config --global core.filemode false


These show up in my
~/.gitconfig
file:

[core]
editor = vim
autocrlf = true
fileMode = false


however, my repositories continue to check filemodes and continue to commit Windows line endings. I have to execute the
git config
command within each repository or the configs don't get loaded.

What's happening?

Answer

Do you have overrides in your local git repo config file?

If you cd to your repository and run:

$ cat .git/config

Are there any settings in there with the same keys but different globals to your global presets?