Skip to content

Commit ac6c0cc

Browse files
committed
Clarify the location of the Windows-specific ProgramData config
On Windows, there is no (single) `/etc/` directory. To address that, in conjunction with the libgit2 project, Git for Windows introduced yet another level of system-wide config files, located in C:\ProgramData (and the equivalent on Windows XP). Let's spell this out in the documentation. This closes #470 (because there was no reaction in three months in that Pull Request). Signed-off-by: Johannes Schindelin <[email protected]>
1 parent d6336bc commit ac6c0cc

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

Documentation/git-config.txt

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -254,9 +254,12 @@ $GIT_DIR/config::
254254
Repository specific configuration file.
255255

256256
On Windows, as there is no central `/etc/` directory, there is yet another
257-
config file, intended to contain settings for *all* Git-related software
258-
running on the machine. Consequently, this config file takes an even lower
259-
precedence than the `$(prefix)/etc/gitconfig` file.
257+
config file (located at `$PROGRAMDATA/Git/config`), intended to contain
258+
settings for *all* Git-related software running on the machine. Consequently,
259+
this config file takes an even lower precedence than the
260+
`$(prefix)/etc/gitconfig` file. Typically `$PROGRAMDATA` points to
261+
`C:\ProgramData` (on Windows XP the equivalent in `$ALLUSERSPROFILE` is used,
262+
i.e. `C:\Documents and Settings\All Users\Application Data\Git\config`).
260263

261264
If no further options are given, all reading options will read all of these
262265
files that are available. If the global or the system-wide configuration

0 commit comments

Comments
 (0)