Skip to content

Instantly share code, notes, and snippets.

View ross-urban's full-sized avatar

Ross Urban ross-urban

View GitHub Profile
@ross-urban
ross-urban / zsh.rc
Created January 31, 2018 23:00
Delete local git branches with deleted remotes
function orphaned-branches {
git branch -vv | cut -c 3- | awk '$4 ~/gone\]/ { print $1 }'
}
function gitclean {
git remote -v prune origin
echo "WARNING: The following branches will be deleted!"
RESPONSE=$(orphaned-branches)
echo "$RESPONSE"
echo

Keybase proof

I hereby claim:

  • I am ross-urban on github.
  • I am rossurban (https://keybase.io/rossurban) on keybase.
  • I have a public key ASDxfLzB7bVLfeoZrnbr4vvJyh5JiylWcoAzqP3xyjTJ9Ao

To claim this, I am signing this object: