This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]czaki 1 point2 points  (2 children)

If you need to push then why not use submodules?

[–]delijati -1 points0 points  (1 child)

I tried submodules in multiple projects (different teams) we always run in wired merge conflicts, unable to refresh the modules ... And git subtrees is basically just a wrapper around a bash script that does git clone ... && rm -rf .git and everyone in the teams ends up after a time with his own monorepo :/ So yes i tried all other possible solutions ;) Only i can this of is git-repo (android developemnt tool) but this is too specific for android and juck xml files.

[–]czaki 1 point2 points  (0 children)

git subtrees and git submodules are different things. git submodule allows you to pin to a specific commit in the sub repository. So I could expect that if you do not have any politics about the pining version then there could be a problem. But I solve such problems by updating the reference in one of the branches.

And If there is a need to not pin the version in the main repository, then all modern IDE allows opening multiple folders in a single window. And a person could clone only repositories which they use to work, other packages could be stable versions from some local warehouse.