Splitting up a Repository

One thing I think causes problems with other VCSs, is the way a repository is a single unit. There’s lots of discussions online between using a “monorepo”, using submodules, etc.

At some point, a project becomes more complex, and it’s necessary or desireable to split up code or combine it form places that were previously the same or separate.

This may well not be possible, but as changes are in theory self-standing (and assuming for a bit that no other files are involved), then it feels like it should be possible (or at least easier than in other VCS systems) to separate out files and their changes into separate smaller repositories - much the same as we can just re-organise directories or other forms of data to be more hierarchical and easier to navigate.

Having used ZFS a reasonable amount, the fact that I can break down a filesystem to be as granular as I like, and then snapshot just one system, change settings, or apply operations to the parent and all its children, is a really useful and powerful feature. It’s not exactly uncommon to want to move files around and re-organise, and yet, git and bazaar to the best of my knowledge have no real way to handle this elegantly.

Pijul’s own organisation may be a perfect example of this. Now we have (or will have) separate crates for libpijul, for the business logic behind the CLI, and the CLI itself. IT’d be fantastic longer-term if pijul had a way we can split things up like that, and easily apply changes to just one element, but perhaps tag or correlate dependencies between the project at a larger scope. I reckon if possible, this coule make v2 an extremely powerful tool, and even git-using sceptics would probably have to admit that this is something lacking in every other system out there.