gitconfig(1):
If not set explicitly with --file, there are four files where git config will search for configuration options:
...
$(prefix)/etc/gitconfig
System-wide configuration file.
What is $(prefix)
on $(prefix)/etc/gitconfig
?
gitconfig is used to store a per-user configuration as fallback values for the . git/config file. The file /etc/gitconfig can be used to store a system-wide default configuration. The configuration variables are used by both the Git plumbing and the porcelains.
How to do a git config global edit? The global git config is simply a text file, so it can be edited with whatever text editor you choose. Open, edit global git config, save and close, and the changes will take effect the next time you issue a git command. It's that easy.
If you want to check your configuration settings, you can use the git config --list command to list all the settings Git can find at that point: $ git config --list user.name=John Doe user. [email protected] color. status=auto color.
# There are 3 levels of git config; project, global and system.
The prefix
environment variable git was compiled with. Usually, it's /usr/local
, so the path is /usr/local/etc/gitconfig
.
More information can be found in the INSTALL
file in the git repository.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With