How can I overwrite, not merge, one remote branch into another branch?

后端 未结 4 509
慢半拍i
慢半拍i 2021-02-02 08:33

I have two branches. Staging and Beta. Staging has code in it ( including files ), that I do not want at all. How can I make Beta completely overwrite Staging, so that none of t

4条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-02-02 08:40

    You can simple delete staging and re-create it based on beta:

    git branch -D staging
    git checkout beta
    git branch staging
    

提交回复
热议问题