Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

What's the best way to manage projects that share code

hans anderson November 19, 2012

Hi,

I have two projects that share 90% of their codebase with eachother. What is the best way to manage them on stash so that when I make changes, the shared code is updated for both projects but the code that is unique to each one stays unique?

-hans

1 answer

1 vote
Colin Goudie
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 19, 2012

The 'correct' way is to modularise your code.

That way the shared code goes in it's own module and can be pulled in by whatever build system you use. e.g. Maven, you declare a dependency

However, if not possible, or impractical now, you could look at using something like git sub-modules.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events