Skip to content

Instantly share code, notes, and snippets.

@antenore
Last active April 13, 2018 21:47
Show Gist options
  • Save antenore/eb01f239f6709f85d97f9e8534c24aa7 to your computer and use it in GitHub Desktop.
Save antenore/eb01f239f6709f85d97f9e8534c24aa7 to your computer and use it in GitHub Desktop.
# From master
## Rename local branch master to v1.1
git branch -m v1.1
## Delete old master
git push origin :master v1.1
## Reset the upstream branch for the v1.1 local branch
git push origin -u v1.1
# From next
## Rename local branch next to master
git branch -m master
## Delete old next
git push origin :next master
## Reset the upstream branch for the master local branch
git push origin -u master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment