How do I delete a Git branch locally and remotely?

后端 未结 30 3617
被撕碎了的回忆
被撕碎了的回忆 2020-11-21 04:11

I want to delete a branch both locally and remotely.

Failed Attempts to Delete a Remote Branch

$ git branch -d         


        
30条回答
  •  耶瑟儿~
    2020-11-21 04:50

    You can also use the following to delete the remote branch

    git push --delete origin serverfix
    

    Which does the same thing as

    git push origin :serverfix
    

    but it may be easier to remember.

提交回复
热议问题