- Published
- Author
- Soniya Rayabagi
We can Rename the current local Git branch name by,
• Switch to the main via the command
• Enter the following command to rename a Git branch
• To ensure that the rename was successful, retrieve the current status of the branch using the
• Switch to the main via the command
git checkout master.• Enter the following command to rename a Git branch
git branch -m old-name new-name .• To ensure that the rename was successful, retrieve the current status of the branch using the
git branch -a.