Git Monorepo vs Multi-repo vs Submodules vs subtrees : Explained

Posted by sshetty03@reddit | programming | View on Reddit | 196 comments

I have seen a lot of debates about whether teams should keep everything in one repo or split things up.

Recently, I joined a new team where the schedulers, the API code, the kafka consumers and publishers were all in one big monorepos. This led me to understand various option available in GIT, so I went down the rabbit hole to understand monorepos, multi-repos, Git submodules, and even subtrees.

Ended up writing a short piece explaining how they actually work, why teams pick one over another, and where each approach starts to hurt.