Created
June 16, 2017 15:29
-
-
Save PYuen1029/023308ae41aca82e9544a80f36fd1845 to your computer and use it in GitHub Desktop.
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] | |
# one-line log | |
l = log --pretty=format:"%C(yellow)%h\\ %ad%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date=short | |
a = add | |
ap = add -p | |
c = commit --verbose | |
ca = commit -a --verbose | |
cm = commit -m | |
cam = commit -a -m | |
m = commit --amend --verbose | |
d = diff | |
ds = diff --stat | |
dc = diff --cached | |
dp = diff HEAD^ HEAD | |
dp1 = diff HEAD~1 HEAD | |
dp2 = diff HEAD~2 HEAD | |
dp3 = diff HEAD~3 HEAD | |
dp4 = diff HEAD~4 HEAD | |
s = status -s | |
co = checkout | |
cob = checkout -b | |
# list branches sorted by last modified | |
b = "!git for-each-ref --sort='-authordate' --format='%(authordate)%09%(objectname:short)%09%(refname)' refs/heads | sed -e 's-refs/heads/--'" | |
bd = branch -d | |
# list aliases | |
la = "!git config -l | grep alias | cut -c 7-" | |
ac = !git add . && git commit -am | |
pod = pull origin development |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment