Last active
August 26, 2020 13:45
-
-
Save milosjanda/a7461ec6a5474fc98e131d19d4a805fc to your computer and use it in GitHub Desktop.
Git 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
[alias] | |
br = branch | |
brd = branch -d | |
brD = branch -D | |
# brp = "!git branch --merged | grep -v '\\*\\|development' | xargs -n 1 git branch -d" | |
brp = !git branch -vv | grep 'origin/.*: gone]' | awk '{print $1}' | xargs git branch -D | |
brv = !git -P branch -va | |
bru = !git fetch && git reset origin/$(git branch --show-current) --hard | |
ci = commit | |
co = checkout | |
cp = cherry-pick | |
df = diff | |
dfc = diff --cached | |
dfw = diff --word-diff | |
dump = cat-file -p | |
hist = log --pretty=format:\"%h %ad | %s%d [%an]\" --graph --date=short | |
pp = pull --prune | |
puf = push -f | |
rba = rebase --abort | |
rbc = rebase --continue | |
rbm = !git fetch && git rebase -i origin/master | |
rbi = rebase -i | |
rh = reset HEAD | |
rhh = reset --hard HEAD | |
rhs = reset --soft HEAD^1 | |
st = status | |
type = cat-file -t | |
aap = !git add . && git commit --amend --no-edit && git push --force |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment