4 ms·
I have a simple question: are monorepos possible in git? What is the upper limit of contributions per day for git to be effective in a monorepo?
by pm90 8y ago
I have a simple question: are monorepos possible in git? What is the upper limit of contributions per day for git to be effective in a monorepo?
- CydeWeys 8y agoAbsolutely. Most monorepos are git. The entire commit history of Linux kernel development exists as a single git repository which you can check out here: https://github.com/torvalds/linux https://github.com/torvalds/linux (Indeed, git was developed for this very purpose.) And it's very doubtful you're going to become larger than Linux. If your company becomes so large that git can't handle all of your code then quite frankly you've exceeded beyond your wildest dreams. Worrying about Google scale for your code repo when you're a startup is the ultimate counting chickens before they hatch.
- beojan 8y agoI really wouldn't call the Linux kernel a monorepo. Not compared to Microsoft keeping all of Windows in a single repo. The problems start when you can't clone the repo within an hour or so, because git doesn't allow partial clones like SVN did.
- WorldMaker 8y agoWhich is why Microsoft built GitVFS and has been contributing all sorts of interesting performance work to upstream git. Microsoft's devops work with Windows and the git transition is full of interesting blog posts and stories and metrics.
- CydeWeys 8y agoAll of the Linux source code is in a single repo. How is that not a monorepo? How are you defining monorepo if not this? The entire Windows codebase is also a monorepo. It just happens to be a bigger one.
- beojan 8y agoI'd define a monorepo as multiple loosely (or un-) coupled projects in the same repository. The Linux kernel is a single strongly coupled project. Nevertheless, whether or not you should keep your code in a single repository is more a question of the sheer size of the repository than of whether the code logically belongs in the same place.
- CydeWeys 8y agoMakes sense. But yeah, even the total code of all projects combined at a startup isn't likely to get anywhere close to the scale of the Linux repo, so it's at least a good example of how far you can get with a single large git repo (regardless of the relatedness of the contents therein).
- gowld 8y agoAm I reading correctly that Linux only has <300 commits per day? (<100K per year, 800K in histoy) https://github.com/torvalds/linux/commits/master?after=3bd6e94bec122a951d462c239b47954cf5f36e33+100000 https://github.com/torvalds/linux/commits/master?after=3bd6e... That's a lot for a code base, but not a lot for a configuration base that has commits automatically generated by various tools. Anyway, Linus advertised that git could apply 3 commits/sec in 2005: https://git.wiki.kernel.org/index.php/GitBenchmarks https://git.wiki.kernel.org/index.php/GitBenchmarks