Skip to content

Instantly share code, notes, and snippets.

@capsulecorplab
Last active December 1, 2022 21:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save capsulecorplab/401ba2fe0857a328f2a626adbf078cc6 to your computer and use it in GitHub Desktop.
Save capsulecorplab/401ba2fe0857a328f2a626adbf078cc6 to your computer and use it in GitHub Desktop.
.gitconfig for git aliases
[alias]
a = add
ap = add -p
b = branch -v
bd = branch -d -v
bD = branch -D -v
cl = clone
clr = clone --recurse-submodules
c = commit --verbose
ca = commit --amend --verbose
can = commit --amend --verbose --no-edit
co = checkout
cob = checkout -b
com = checkout main
cod = checkout dev
cp = cherry-pick
cpc = cherry-pick --continue
cpa = cherry-pick --abort
d = diff
ds = diff --stat
dc = diff --cached
f = fetch --prune
fo = fetch origin --prune
fa = fetch --all --prune
i = init
jk = reset --soft HEAD~
l = log
lo = log --oneline
la = log --graph --all
dag = log --graph --oneline --all
rb = rebase
rbc = rebase --continue
rba = rebase --abort
rbi = rebase --interactive
rv = remote -v
rh = reset --h
rs = reset --s
s = status
sh = show
shn = show --name-only
h = show HEAD
hn = show HEAD --name-only
p = push
pf = push -f
psu = push --set-upstream
psuo = push --set-upstream origin
[core]
editor = /usr/bin/vim
autocrlf = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment