I was thinking of exactly that. Or maybe, for an extreme version of this, one could create a Docker image with the whole dev environment, start the container at the login, bind mount / of the host somewhere and work from there. Then Ctrl-D and it's gone.