blog
blog copied to clipboard
Git常用操作
Git
git 删除远程分支:git push origin --delete{
将某次提交应用到指定分支 git checkout {branch-name} git cherry-pick {hash}
重命名分支名
- Rename your local branch.
git branch -m new-name
- Delete the old-name remote branch and push the new-name local branch.
git push origin :old-name new-name
- Reset the upstream branch for the new-name local branch.
git push origin -u new-name