【Git】创建分支和删除分支并更新到远程

git查看项目所有分支

$ git branch -a

git删除远程分支

git push origin --delete 分支名

git删除本地分支

$ git branch -D wgy_mirror

git创建分支

git branch 分支名
git checkout 切换分支

(可以合并为)等价于:

git checkout -b 分支名

git推送本地分支到远端

git push --set-upstream origin 分支名

 

posted @ 2022-07-26 11:21  王广元  阅读(170)  评论(0)    收藏  举报
分享到: