1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-22 16:22:08 +02:00
tldr/pages/common/git-config.md
Waldir Pimenta 87fb4e13bd git-config: overhaul page (#1402)
- expand description of local and global options
- adjust example descriptions for clarity
- change the descriptions of the get/set/remove examples to be more generic 
- change the alias example to a more useful one
- use "configuration entries" instead of "configuration options" to match both preset options and aliases
2017-06-15 23:30:21 +01:00

28 lines
794 B
Markdown

# git config
> Manage custom configuration options for git repositories.
> These configurations can be local (for the current repository) or global (for the current user).
- List only local configuration entries (stored in `.git/config` in the current repository):
`git config --list --local`
- List only global configuration entries (stored in `~/.gitconfig`):
`git config --list --global`
- List all configuration entries that have been defined either locally or globally:
`git config --list`
- Get the value of a given configuration entry:
`git config alias.unstage`
- Set the global value of a given configuration entry:
`git config --global alias.unstage "reset HEAD --"`
- Revert a global configuration entry to its default value:
`git config --global --unset alias.unstage`