You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As far as I know, there are four config locations:
Config file location
--global use global config file
--system use system config file
--local use repository config file
--worktree use per-worktree config file
Local and worktree are repository specific so let's ignore them for the moment.
Let me also note that what is called "global" config here is what I would call "user" config since it is in the user's home folder so it is global only in the sense that it is affecting all repositories from the same user.
Furthermore, what is called "local" should perhaps be called "repo" because it would better explain what it is affecting.
With that in mind, my questions are:
Why is there a second "system" config file in %ALLUSERSPROFILE%\Git?
%ALLUSERSPROFILE%\Git is writeable by all users of the system while %ProgramFiles%\Git\mingw64\etc is only writeable by Administrators. If both define the same setting which one will take precedence?
Why is there no dedicated switch (except -f file) to reference that config directly?
Are the contents of this config file preserved on reinstall? If not, why not?
TL;DR — if system-wide settings are not meant to be overrideable by any random user and are stored in application folder (and thus lost on uninstall), what is the rationale behind having this second "system" file?
I apologize in advance if this is explained somewere in documentation but I couldn't find it.
The text was updated successfully, but these errors were encountered:
Why is there a second "system" config file in `%ALLUSERSPROFILE%\Git`?
Where do you get that from?
Why is there no dedicated switch (except `-f file`) to reference that config directly?
This file is not supported by "official" Git. Only by Git for Windows. We have a PR up at gitgitgadget#148, but I did not get to it yet (there are so many patches I need to upstream, still, and if you want to help, I will very much appreciate all you can do to review patches on the Git mailing list).
Are the contents of this config file preserved on reinstall?
Partially. It depends on the choices you make in the installer. Those choices will override what is in that file.
Setup
defaults?
to the issue you're seeing?
No.
Details
CMD (irrelevant, see below)
This is more of a question than a bug report, I need clarification about configuration files on Windows platform.
Namely, when I run:
git config -l --system --show-origin
I get the following output:
And when I run:
git config -l --global --show-origin
I get the following output:
But when I run:
git config -l --show-origin
I also get the following part in the output:
As far as I know, there are four config locations:
Local and worktree are repository specific so let's ignore them for the moment.
Let me also note that what is called "global" config here is what I would call "user" config since it is in the user's home folder so it is global only in the sense that it is affecting all repositories from the same user.
Furthermore, what is called "local" should perhaps be called "repo" because it would better explain what it is affecting.
With that in mind, my questions are:
%ALLUSERSPROFILE%\Git
?%ALLUSERSPROFILE%\Git
is writeable by all users of the system while%ProgramFiles%\Git\mingw64\etc
is only writeable by Administrators. If both define the same setting which one will take precedence?-f file
) to reference that config directly?TL;DR — if system-wide settings are not meant to be overrideable by any random user and are stored in application folder (and thus lost on uninstall), what is the rationale behind having this second "system" file?
I apologize in advance if this is explained somewere in documentation but I couldn't find it.
The text was updated successfully, but these errors were encountered: