History
One of the earliest approaches I had to try getting a proper environment at the per-project level was asdf. It worked out fairly well for a few years, but then I noticed that my various novels and stories were getting fragile.
There were limitations that asdf
couldn't handle easily which meant I needed something more reliable. That led me into Nix which is my current setup because entering the directory sets up that project's settings while still giving me the reproducibility I need for my novels.
This means that most of my projects now have a ./flake.nix
and a ./flake.lock
in the root level.