Manage multiple git release branches for multiple customers

前端 未结 2 1153
孤独总比滥情好
孤独总比滥情好 2021-02-08 21:33

My company has a piece of software we sell to multiple customers. But every customer have some different requirements (more than just \"Put our logo here\"). The core i

2条回答
  •  独厮守ぢ
    2021-02-08 21:48

    Thanks for @AnimiVulpis. His/Her answer gave me a hint. Here's my solution: (also base on the nvie's strategy)

    1.Extract the exact common parts from project. Create a branch named shared/develop

    2.Based on the shared/develop, creating a customer1's branch

    git checkout -b local/customer1/develop origin/shared/develop
    #push this new branch to remote
    git push origin local/customer1/develop:origin/customer1/develop
    git push origin local/customer1/develop:origin/customer1/master
    

    3.Same with step 2. create other customers' branch.

    4.All the common parts used for all customers should work on shared/develop branch.

    4.All the feature development just for the customerN should work on its own customerN/develop branch.It should be note that all the customers' branches should merge from shared/develop branch before a new feature coding.

提交回复
热议问题