And*_*imm 18 git branch git-flow
是否可以使用git-flow重命名功能分支?
我试图寻找了git flow help和git flow feature help,也是混帐流的cheatsheet,但也没有什么.
或者,只是使用它是否安全git branch -m feature/new_name?
Cod*_*ard 32
是的.
你可以这样做但是如果你推动你的分支并且有人正在使用它,你将需要更新它们的变化.
gitflow分支与任何其他分支没有什么不同.
Rename local branchGit初学者(普通方式)
#Checkout new branch and delete the old one
git checkout -b <new_name>
git branch -D <old_name>
#Use the short git branch move (-m flag)
git branch -m <old_name> <new_name>
#Use the short git branch move (–move flag)
git branch --move <old_name> <new_name>
Run Code Online (Sandbox Code Playgroud)
Advanced: Manually rename branch(不推荐 - 又名不要在家里试试!!!)
Rename the old branch under .git/refs/heads to the new name
Rename the old branch under .git/logs/refs/heads to the new name
Update the .git/HEAD to point to your new branch name.
Sit back and Enjoy GIT :-)
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
13085 次 |
| 最近记录: |