Skip to content

Instantly share code, notes, and snippets.

@ParikshitChavan
Created February 15, 2022 08:10
Show Gist options
  • Select an option

  • Save ParikshitChavan/9cd0d946a454fddc2664d945fca0bded to your computer and use it in GitHub Desktop.

Select an option

Save ParikshitChavan/9cd0d946a454fddc2664d945fca0bded to your computer and use it in GitHub Desktop.
delete all local local branches which have been deleted from remote
git fetch -p && git branch -vv | awk '/: gone]/{print $1}' | xargs git branch -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment