We have two C# projects…a Common project and a WEB UI project. Both of them are in separate repositories.
The Common Project references the UI Project and when we work, we always work in the common project, even making changes to the UI project from within it.
The problem is, when we pull, we always end up having to pull from two separate projects which can cause some confusion when local builds start failing because someone forgot to pull from the other repository.
We have tried Submodules and the Subtree merge strategy. We used the Common project as our main project (which I will now refer as the parent) and the UI project as the sub-project (which I will now refer to as the child). Then we just changed the reference from the Parent to the Child to point to the subdirectory containing the subtree/submodule. Unfortunately when we make changes to the child project, they don’t get pushed back up with the parent project using either of the two strategies mentioned above when doing a Commit and Push. It seems as if the only thing that Subtree and Submodules do is automatically PULL into the local child UI repository whenever you pull from the Parent remote repository.
Is there any way possible to make it so when we push from the parent it also pushes the changes from the child?
It looks like the best way to accomplish this is just to create a custom command in GIT to automate the process of pulling from two repositories with one command.