Reputation: 381
I'm on git version 2.8.3.windows.1 and a bit perplexed about where the core.autocrlf
setting is actually being stored. In Git Extensions it shows as "not set", however I get the following when I query git config:
$ cd /c <-- i.e. not a repo
$ git config --get core.autocrlf
false
$ git config --global --get core.autocrlf
(nothing)
$ git config --system --get core.autocrlf
(nothing)
$ git config -l
core.symlinks=false
core.autocrlf=false
core.fscache=true
...
$ git config --system -l
credential.helper=manager
$ git config --global -l
core.editor="C:/Program Files (x86)/GitExtensions/GitExtensions.exe" fileeditor
core.quotepath=false
color.ui=auto
... (not here either)
$ git config --local -l
fatal: unable to read config file '.git/config': No such file or directory
The .gitconfig file also doesn't have it
$ cat ~/.gitconfig
[core]
editor = \"C:/Program Files (x86)/GitExtensions/GitExtensions.exe\" fileeditor
quotepath = false
So I get how GitExt is showing it as "not set", but I don't understand at all how git config -l
is getting the value for core.autocrlf
. And I can't seem to get rid of it to re-write it:
$ git config --unset core.autocrlf
fatal: not in a git directory
$ git config --unset --global core.autocrlf
$ git config -l
core.symlinks=false
core.autocrlf=false
core.fscache=true
...
Thanks.
Upvotes: 1
Views: 1270
Reputation: 78873
Yes. Beginning with Git for Windows 2.5.0, there is a system-wide Windows configuration area, so that all Windows clients can interoperate.
This new path is %PROGRAMDATA%\Git\config
.
Despite the name, the "global" configuration area is not global on Windows, it is tied to a particular Git for Windows installation.
Upvotes: 4