Created
March 19, 2018 14:36
-
-
Save colinodell/89ee20346628d4f31aca4a7118b159a0 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] | |
p = "!git pull --ff-only" | |
fixup = !sh -c 'REV=$(git rev-parse $1) && git commit --fixup $@ && git rebase -i --autostash --autosquash $REV^' - | |
cleanup = "!git branch --merged | grep -v -P '^\\*|master|develop' | xargs -n1 -r git branch -d" | |
children = "!bash -c 'c=${1:-HEAD}; set -- $(git rev-list --all --not \"$c\"^@ --children | grep $(git rev-parse \"$c\") ); shift; echo $1' -" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment