2015-12-17 10:09:03 +00:00
|
|
|
# git config
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
> Get and set repository or global options.
|
2015-12-17 10:09:03 +00:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Print list of options for current repository:
|
2015-12-17 10:09:03 +00:00
|
|
|
|
|
|
|
`git config --list --local`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Print global list of options, set in ~/.gitconfig:
|
2015-12-17 10:09:03 +00:00
|
|
|
|
|
|
|
`git config --list --global`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Get full list of options:
|
2015-12-17 10:09:03 +00:00
|
|
|
|
|
|
|
`git config --list`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Get value of alias.ls option:
|
2015-12-17 10:09:03 +00:00
|
|
|
|
|
|
|
`git config alias.st`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Set option alias.ls=status in file ~/.gitconfig:
|
2015-12-17 10:09:03 +00:00
|
|
|
|
|
|
|
`git config --global alias.ls "status"`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Remove option alias.st from ~/.gitconfig:
|
2015-12-17 10:09:03 +00:00
|
|
|
|
|
|
|
`git config --global --unset alias.st`
|