Well, you'll have to install and keep those packages somewhere on your system. And maybe a few months from now after your latex distribution got updated by the system your document suddenly no longer compiles.
What I want is something like npm-like package management for this, where the packages are just kept there next to the document. I don't care if I'll have a package 20 times on my system either, storage hasn't been a concern in many years.
Maybe running Latex in a container would meet your requirements?
There's a package for that:
Write a Nix expression to compile your document. That way you can be sure it keeps working. I did this long ago for my PhD thesis and other papers.
> And maybe a few months from now after your latex distribution got updated by the system your document suddenly no longer compiles.
I'm using LaTeX 2e for 25+ years. This has literally never happened to me. If that's not stability, I don't know what is. LaTeX documents I wrote in my grad days still compile for me. I just checked and it does. I do keep the dependency packages myself in my folder.
Has this issue ever happened to anyone? Why would LaTeX distribution getting updated break my documents? It's still the same latex compiler and the same base styles and packages!