I would like to move Haskell projects between my work computer and my laptop on a USB stick. I'm using the stack build system. My laptop is very often away from the Internet, sometimes when I initially insert the USB, so if I just copy the project, I'll be missing the GHC toolchain and all the libraries on the laptop. I want to be able to plug in to the laptop and work, even without being connected.
Various solutions I've seen tell me to use certain stack flags and copy over the ~/.stack
directory, but I've never succeeded in getting a successful build - and it seems a rather fragile approach. I would also appreciate a bit of automation, and ideally some versioning support.
Would Nix help with this scenario? How about Nix' Docker integration features? (I have minimal Nix and no Docker experience, but I'm willing to learn if it will help me here.) I would like to retain the ability to use my laptop-based tooling, such as VS Code.