Created
September 5, 2018 19:44
-
-
Save JessePreiner/45e1518f5fc96c28f6a5656c3f5bf8ef to your computer and use it in GitHub Desktop.
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] | |
unstage = reset HEAD -- | |
ca = commit --amend | |
cm = commit -m | |
co = checkout | |
cb = checkout -b | |
fh = log -p | |
dc = diff --cached | |
aa = add -A | |
st = status -sb | |
panic = rebase --abort | |
df = diff HEAD~1..HEAD | |
lg3 = log -n 40 --pretty=format:'%C(auto)%h%Creset%C(auto)%d%Creset %Cgreen%ad%Creset %s %C(cyan)%an%Creset %Cgreen(%ar)%Creset' --date=short --graph --all | |
lg2 = log -n 40 --all --graph --decorate --color --oneline --abbrev-commit | |
lg = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) %C(reset) %C(bold green)(%ar) %C(reset)%C(dim white)(%C(blue)committer: %cn) %C(reset) %C(auto)%d%C(reset)%n %C(white)%s%C(reset)%C(dim white) -%C(green)by %an %C(reset) %C(dim white)%C(reset)' | |
permission-reset = "!git diff -p | grep -E \"^(diff|old mode|new mode)\" | sed -e \"s/^old/NEW/;s/^new/old/;s/^NEW/new/\" | git apply" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment