Skip to content

Instantly share code, notes, and snippets.

@tisseurdetoile
Last active September 28, 2016 14:21
Show Gist options
  • Save tisseurdetoile/3a5c56dfa49e530186fb72eb793ead98 to your computer and use it in GitHub Desktop.
Save tisseurdetoile/3a5c56dfa49e530186fb72eb793ead98 to your computer and use it in GitHub Desktop.
Git configuration
git config --global user.name yourName
git config --global user.email yourMail@yourdomain.net
git config --global color.diff always
git config --global color.diff.frag magenta bold
git config --global color.diff.meta yellow bold
git config --global color.diff.whitespace red reverse
git config --global core.whitespace '-trailing'
git config --global diff.mnemonicPrefix true
git config --global diff.renames true
git config --global diff.wordRegex .
git config --global fetch.prune false
git config --global log.abbrevCommit true
git config --global log.follow true
git config --global merge.conflictStyle diff3
git config --global merge.log true
git config --global merge.ff false
git config --global pager.diff "diff-so-fancy | less --tabs=2 -RFX"
git config --global pager.show "diff-so-fancy | less --tabs=2 -RFX"
git config --global pull.rebase preserve
git config --global push.default upstream
git config --global push.followTags true
git config --global rerere.enabled true
git config --global rerere.autoupdate true
git config --global alias.oops "commit --amend --no-edit"
git config --global alias.s "status"
git config --global alias.lg "log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all"
git config --global alias.lg2 "log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all"
git config --global alias.lg-ascii "log --graph --pretty=format:'%h -%d %s (%cr) <%an>' --abbrev-commit"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment