Created
June 3, 2013 21:23
-
-
Save iautom8things/5701541 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
[user] | |
name = Manuel Zubieta | |
email = [email protected] | |
[alias] | |
; ----------------------------- ; | |
; Shortcuts for common commands ; | |
; ----------------------------- ; | |
h = help | |
co = checkout | |
sm = submodule | |
st = status | |
stat = status | |
br = branch | |
ci = commit -v | |
d = diff | |
; --------------------------- ; | |
; Shortcuts for diff commands ; | |
; --------------------------- ; | |
; diff by word | |
dword = diff --word-diff | |
dw = diff --word-diff | |
; diff by word since last commit | |
dwsl = diff --word-diff HEAD^..HEAD | |
; diff status -- per file # lines changed | |
dstat = diff --stat | |
dst = diff --stat | |
; diff status since last commit | |
dstsl = diff --stat HEAD^..HEAD | |
; ------------------------------ ; | |
; Shortcuts for logging commands ; | |
; ------------------------------ ; | |
; Log on One Line | |
lol = log --graph --decorate --pretty=oneline --abbrev-commit --all | |
lola = log --graph --pretty=format:'%C(black)%h%C(bold white) -%C(bold yellow)%d%Creset %s %C(bold green)(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all | |
whatsnew = log origin/master@{1}..origin/master@{0} | |
; git rid of any uncommitted changes | |
fuckit = reset --hard | |
; complement to "git add", removes the files from the staging area | |
unstage = reset HEAD -- | |
us = reset HEAD -- | |
; (un)hide a file from git so that any unsaved changes do not get tracked | |
hide = update-index --assume-unchanged | |
unhide = update-index --no-assume-unchanged | |
hidden = "!git ls-files -v | grep ^h | cut -c 3-" | |
; Undo the last commit so that you can alter it | |
undolastcommit = reset --soft HEAD^ | |
ulc = reset --soft HEAD^ | |
; Resave the new changes you've made to the last commit | |
redolastcommit = commit -v -c ORIG_HEAD | |
rlc = commit -v -c ORIG_HEAD | |
[color] | |
branch = auto | |
diff = auto | |
interactive = auto | |
status = auto | |
[diff] | |
algorithm = patience |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment