Skip to content

Instantly share code, notes, and snippets.

@FabienSalles
Last active March 4, 2024 23:11
Show Gist options
  • Save FabienSalles/5886184 to your computer and use it in GitHub Desktop.
Save FabienSalles/5886184 to your computer and use it in GitHub Desktop.
Git configuration
[alias]
st = status -sb
co = checkout
amend = commit --amend -C HEAD
lg = log --pretty=format:\"%C(yellow)%h %C(blue)%ad%C(red)%d %C(reset)%s%C(green) [%cn]\" --decorate --date=short
undo = reset --soft HEAD^
lg1 = log --graph --all --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(bold white)— %an%C(reset)%C(bold yellow)%d%C(reset)' --abbrev-commit --date=relative
unchanged = update-index --assume-unchanged
[color]
ui = true
[help]
autocorrect = 1
[rerere]
enabled = true
[pull]
rebase = true
[rebase]
autosquash = true
[credential]
helper = cache --timeout=3600
[core]
# npm install -g diff-so-fancy cf https://github.com/stevemao/diff-so-fancy
pager = diff-so-fancy | less --tabs=1,5 -R
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment