Let’s say you have four products each with their own release schedule. Each product has 50% shared code (common functionality across all products) and 50% product specific code.
Do you need a separate source control branch for each product? Should common functionalities always be developed in one of the four product branches and merged to the other products later?
Typical Scenario: Product A is being released next month and requires core (shared) enhancement 1, product B is being released in four months and requires core (shared) enhancement 2 (which will take three months to complete).
I keep shared code in it's own product folder. Then use svn:externals to share the code amongst the other products. It's slightly painful to handle branching and merging, but it's better than having four copies of the shared code in the repository. Something like this (replace trunk with /branches/RB-1.0.0 or /tags/REL-1.0.0 for release branches and tagged releases):
/core/trunk
/product_a/trunk
/core (svn:externals 'core /core/trunk')
/product_b/trunk
/core (svn:externals 'core /core/trunk')
/product_c/trunk
/core (svn:externals 'core /core/trunk')
/product_d/trunk
/core (svn:externals 'core /core/trunk')
UPDATE0: Note that /product_a/tags/REL-1.0.0 might use /core/tags/REL-1.0.0 while /product_b/tags/REL-1.0.0 might use /core/tags/REL-1.1.0
Common functionality can be developed in a separate Platform branch, with each product getting its own branch for the product-specific development.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With