Git Config
Config File
Global Config
~/.gitconfig
Local Config
.git/configgit config multiple url
Configuration
[i18n]
commitencoding = UTF-8
logoutputencoding = UTF-8
[core]
eol = 'lf'
autocrlf = input
excludesfile = /Users/matt/.gitignore_global
[branch "master"]
rebase = true
[branch]
#autosetuprebase = always
# git config --global color.diff.meta "blue black bold"
[color]
ui = true
[merge]
tool = extMerge
[mergetool "extMerge"]
cmd = extMerge "$BASE" "$LOCAL" "$REMOTE" "$MERGED"
trustExitCode = false
[diff]
external = extDiff
Notable
receive.fsckObjects
receive.denyNonFastForwards
receive.denyDeletes
core.autocrlf
color.branch
color.diff
color.interactive
color.status
user.signingkey
commit.template
core.editor
Aliases
l = log --pretty=format:"%C(yellow)%h %ad%Cred%d %Creset%s%Cblue [%cn]" --decorate --date=short
again = "!f() { git add -A && git status && git commit -m \"$(git log -1 --format='%s')\" && git push && git l -1; }; f"
d = diff --cached HEAD^
csv = log --pretty=format:'"%h", "%an", "%ae", "%ad", "%s"'
Gitignore
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class
# C extensions
*.so
# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/