suin.io

Git Rename a local branch

suinAugust 2, 2016

Renaming local git branch:

git branch -m old_branch new_branch

I sometimes use this when an issue number of pull requests is wrong.

In the case of changing current branch, it is easier. Just specify new branch name:

git branch -m new_branch