Skip to main content

Rename a git branch

·64 words·1 min· ·
Git Branch Tip
Ariejan de Vroom
Author
Ariejan de Vroom
Jack of all Trades, Professional Software Craftsman

In git, branching is cheap and easy. You do it all the time (you’re not? Well, you should). Sometimes, though, you create a new feature branch, only to come to the conclusion later that the name you gave it does not cover the stuff you’ve been doing.

No problem for git! Renaming a branch is really easy:

git branch -m old_branch new_branch

That’s all.

Related

Best Practice - The Git Development Cycle
·318 words·2 mins
General Git Rebase Merge Branch Svn Best-Practice
Cherry-Picking specific commits from another branch
·323 words·2 mins
Git Cherry-Pick Scm
How to create and apply a patch with Git
·660 words·4 mins
Git Patch Sign-Off