How can I start a clean branch with no ancestry, then commit files progressively?

后端 未结 3 1767
清歌不尽
清歌不尽 2020-12-12 19:22

I have a PHP framework versioned with GIT and I\'m planning several (drastic) changes to its core.

What I want to do is to start working on the new core in a new br

3条回答
  •  攒了一身酷
    2020-12-12 19:31

    What you can do is simply moving to a new branch, git co -b my_new_branch, clean up your code and keep the things you need, and finally commit. That commit, the first on my_new_branch, would then be a clean one.

提交回复
热议问题