opam-nix looks like a neat tool to read Opam files, and pull down dependencies. Thanks @balsoft for letting me know about it! It would be cool to demo how this could be used in this repo.
It would be good to consider if it's still a good idea to let Dune drive the generation of hello.opam. It's already kind of janky how I check that the generated file is up to date, requiring people to re-run dune build in the dev shell to keep it up-to date. I'd want to ensure that the process of adding a new dependency, then re-building the package is smooth. Perhaps we should just get rid of the generate_opam_files and package specification and let Opam drive pulling down the packages?
Merlin and the VS Code Platform extension seems to rely on dune build --watch running in the background, and being able to see the output of the build artifacts in the source directory (under _build). I'm not sure how best to integrate this into a nix flake workflow.