Created
February 10, 2016 02:23
-
-
Save elicwhite/3967fb89907e8dc55109 to your computer and use it in GitHub Desktop.
Git Aliases
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] | |
cleanup = "!git branch --merged | grep -v '\\*\\|master' | xargs -n 1 git branch -d && git remote prune origin" | |
cleanup-remote = "!git branch -r --merged | grep origin | grep -v '>' | grep -v master | xargs -L1 | cut -d"/" -f2- | xargs git push origin --delete" | |
old-branches = "!git for-each-ref --sort=committerdate --format='%1B[1;34m %(authordate:relative) %1B[m %(refname:short) %1B[1;32m%(authorname)%1B[m' refs/remotes" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment