Skip to content

Instantly share code, notes, and snippets.

@Chambras
Last active July 19, 2021 15:12
Show Gist options
  • Save Chambras/53b9b66d69198529b9b2d154f6b4ba22 to your computer and use it in GitHub Desktop.
Save Chambras/53b9b66d69198529b9b2d154f6b4ba22 to your computer and use it in GitHub Desktop.
Git config
[user]
name = {{Name}}
email = {{email}}
[alias]
co = checkout
com = checkout main
cod = checkout dev
ci = commit -m
cane = commit --amend --no-edit
ca = !git add -A && git commit -m
st = status
br = branch --format='%(HEAD) %(color:yellow)%(refname:short)%(color:reset) - %(contents:subject) %(color:green)(%(committerdate:relative)) [%(authorname)]' --sort=-committerdate
df = diff
dfno = diff --name-only master dev
dfns = diff --name-status master dev
rmt = remote -v
pl = pull
ps = push
cl = clone
lg = log --graph --date=relative --pretty=tformat:'%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%an %ad)%Creset'
ln = log --graph --oneline --all
conf = config --global -e
cob = checkout -b
pom = push -u origin main
pod = push -u origin dev
save = !git add -A && git commit -m 'SAVEPOINT'
la = "!git config -l | grep alias | cut -c 7-"
[push]
default = current
[color]
# Enable colors in color-supporting terminals
ui = auto
[core]
autocrlf = input
editor = vi
[init]
defaultBranch = main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment