views:

15

answers:

1

I have the git repository where I am storing 4 different programs based on same code base. Some branches just have the different realization for some features. And others do completely different things(preparing the environment for calculation and calculation itself). There is no problem for me to make 4 different branches for it. But also I need to maintain this on 4 different hardware setups with different makefiles, starting scripts and configs that are slightly different for different branches and hardware setups. Is there a possibility to separate the repositories or I need to design my code excluding overlaps and store things in different folders? What I am looking for is the way to pick 1 branch for program and 1 config file and generate working code.

A: 

I would hesitate to use Git in this fashion. I would prefer to use the branching for code changes and development, and maintain/generate your builds via scripts/makefiles etc. on the same branch (the one that you develop off/merge changes into).

Brian Agnew
Thank you for your input, I have in mind this option but also like to listen other opinions before making a decision. The problem is that i have developed the additional module without any version control system 4 years ago. Now I have improved it but it doesn't work the way I expect it and also the base program was updated and I try to build the git repository on it for testing/debugging purposes separating logical changes into small commits. It is very convinient to use git branches in this case. But for hardware setup configs it is possible to make shell scripts etc.
alcworx