Skip to content

Instantly share code, notes, and snippets.

@juanje
Created June 7, 2011 13:12
Show Gist options
  • Save juanje/1012207 to your computer and use it in GitHub Desktop.
Save juanje/1012207 to your computer and use it in GitHub Desktop.
Delete a remote branch
# Let's say you've created a branch 'my_changes' you have pushed to Github, but now
# you want to remove it.
# Let's also set the remote which point to your Github account is 'origin'
# These are the needed steps:
# 1 - Delete the branch locally
git -D my_changes
# 2 - Push those changes (the delete) to Github
git push origin :my_changes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment