Created
July 19, 2021 03:47
-
-
Save bmsrox/c34e097d0cdfb16c820b7be3ad8a30ae to your computer and use it in GitHub Desktop.
Git config aliases
This file contains hidden or 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
b = branch | |
s = status -s | |
c = !git add --all && git commit -m | |
l = log --pretty=format:'[%C(blue)%h%C(white)]%C(red)%d %C(white)%s -> %C(cyan)%cn, %C(green)%cr' | |
lg = log --all --decorate --oneline --graph --pretty=format:'[%C(blue)%h%C(white)]%C(red)%d %C(white)%s -> %C(cyan)%cn, %C(green)%cr' | |
amend = !git add --all && git commit --amend --no-edit | |
find = "!f(){ git branch | grep $1; }; f" | |
st = !git add --all && git stash | |
sw = "!f(){ git find $1 | xargs git switch; }; f" | |
sws = "!f(){ git st && git find $1 | xargs git switch; }; f" | |
co = "!f(){ git find $1 | xargs git switch; }; f" | |
cos = "!f(){ git st && git find $1 | xargs git checkout; }; f" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment