I will be doing a project that will have a distinct server side (.NET) and client side (JavaScript) which can be developed separately. Does it make more sense to have them as 2 separate git repositories or should they be rather one? What advantages / disadvantages do these approaches have?
Git is a DevOps tool used for source code management. It is a free and open-source version control system used to handle small to very large projects efficiently. Git is used to tracking changes in the source code, enabling multiple developers to work together on non-linear development.
I'd recommend placing the code in two separate folders within the same git repository.
Main reason being that if you make changes to the server that require changes in the client it's easy to see the changes to both in the same change set.
If the client and server code were separate repositories you've have to try and determine manually which change set on the server corresponded to which change set in the client code base.
Personnaly, i create two big folders, one for the client side and the other for the server.
For the client side (I use symfony), I use apache alias. So it's more simple and it's centralized.
Having two repository is the same but it's not as simple to switch between branches. For example, you change the security protocol. You will edit the two sides. So a branch is a good soluton. If you've two separated repositories, you cannot use the same branch.
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