Last active
January 8, 2021 09:01
-
-
Save esynr3z/3026ce8f9e8f370df743a422cdf66a72 to your computer and use it in GitHub Desktop.
My Git aliases
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[alias] | |
a = add | |
b = branch | |
s = status --short | |
c = commit -m | |
d = diff | |
co = checkout | |
dc = diff --cached | |
dw = diff --word-diff | |
ds = diff --stat | |
l = log --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)[%an]%Creset' --decorate | |
ll = log --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)[%an]%Creset' --decorate --numstat | |
tree = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%ad) %C(bold blue)[%an]%Creset' --decorate --date=short | |
feature = checkout -b | |
amend = commit --amend | |
unstage = reset HEAD | |
undo = reset --hard | |
recover = checkout -- | |
last = log -1 HEAD | |
alias = ! git config --get-regexp ^alias\\. | sed -e s/^alias\\.// -e s/\\ /\\ =\\ / | |
panic = !tar cvf ../git_panic.tar . | |
tag-delete = tag --delete | |
tag-delete-remote = push --delete | |
zip = !git archive --format=zip -o ../`basename $PWD`_`git rev-parse --short HEAD`.zip HEAD | |
precommit = !.git/hooks/pre-commit | |
prepush = !.git/hooks/pre-push |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment