Git workflow for maintaining an project extension fork?

前端 未结 2 1015
我寻月下人不归
我寻月下人不归 2021-02-05 16:05

We\'ve forked an OSS project on GitHub and are adding some custom extensions to it. We\'ll want to send some of the changes we make back to the original project (bug fixes and

2条回答
  •  长情又很酷
    2021-02-05 16:24

    It sounds to me like you have already answered your own question. Create a branch called "vanilla" or something which tracks upstream's master branch, and have a "master" branch which contains your custom extensions. Create branches for each thing you do. For bugfixes, start them off of "vanilla". For your own stuff, start them off of master. Every once in a while, merge vanilla into master. To get the bugfixes into your custom extensions branch, you could merge their branches into master directly, or just wait for upstream to accept your bugfix pull requests, and then the next merge from vanilla to master would contain the bugfixes. This seems like a very normal workflow.

提交回复
热议问题