I am moving a project from SVN to GIT.
The project uses a set of SQL procedures. Multiple clients have their own versions of the files, but they also use a CORE set of procedures that is the same for all clients.
Currently what we have on SVN is a one folder containing a CORE folder and multiple folders containing client specific procedures (see "current folder structure" below).
My initial idea was to have one repository containing core files and separate branches that contain additional files per client, but then I realised that it can be quite dangerous and easily become messy if someone pushes files to the wrong branch.
So, my another idea was to have each client's procedures in their own repository and linking the CORE repository as a sub-module in each of them.
Questions:
Here is some additional info that can make my current situation easier to understand:
Rules:
Current deployment process at clients site:
Current folder structure for the project:
├── core
│ ├── proc-core-bar.sql
│ ├── proc-core-csv.sql
│ ├── proc-core-db.sql
│ └── proc-core-foo.sql
├── client-1
│ ├── proc-client-addr.sql
│ ├── proc-client-msgs.sql
│ └── proc-client-ordr.sql
├── client-2
│ ├── proc-client-addr-additional.sql
│ ├── proc-client-addr.sql
│ ├── proc-client-msgs.sql
│ └── proc-client-ordr.sql
├── client-3
│ ├── proc-client-addr-additional.sql
│ ├── proc-client-addr.sql
│ ├── proc-client-msgs.sql
│ └── proc-client-ordr.sql
├── client-4
│ ├── proc-client-addr.sql
│ ├── proc-client-msgs.sql
│ ├── proc-client-ordr-additional.sql
│ └── proc-client-ordr.sql
└── client-5
├── proc-client-addr.sql
├── proc-client-msgs.sql
└── proc-client-ordr.sql
Git submodules
Pro:
Contra:
Git subtrees
Pro:
Contra:
Git slave
Pro:
Contra:
Bit
Pro:
Contra: