Skip to content

Instantly share code, notes, and snippets.

@lucasamonrc
Last active May 16, 2024 04:26
Show Gist options
  • Save lucasamonrc/7babe1656b13b3f5e712e5d2898e29de to your computer and use it in GitHub Desktop.
Save lucasamonrc/7babe1656b13b3f5e712e5d2898e29de to your computer and use it in GitHub Desktop.
My personal git configuration
[user]
name = Lucas Castro
email = lucasamonrc@gmail.com
[core]
editor = vim
[init]
defaultBranch = main
[pull]
rebase = false
[alias]
ci = commit -m
co = checkout
cm = checkout master
cb = checkout -b
st = status -sb
sf = show --name-only
lg = log --pretty=format:'%Cred%h%Creset %C(bold)%cr%Creset %Cgreen<%an>%Creset %s' --max-count=30
incoming = !(git fetch --quiet && git log --pretty=format:'%C(yellow)%h %C(white)- %C(red)%an %C(white)- %C(cyan)%d%Creset %s %C(white)- %ar%Creset' ..@{u})
outgoing = !(git fetch --quiet && git log --pretty=format:'%C(yellow)%h %C(white)- %C(red)%an %C(white)- %C(cyan)%d%Creset %s %C(white)- %ar%Creset' @{u}..)
unstage = reset HEAD --
undo = checkout --
rollback = reset --soft HEAD~1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment