Hello, the nodejs infrastructure in nixpkgs looks quite complex to me. I'm sure that there are good reasons for this. In particular, can someone answer the following questions, as I am not intimately familar with the full NPM ecosystem:
Both of the following approaches change the concept from "one derivation per npm library" to "one or two derivations per npm *application/tool*" (libraries are build together with the application, in the same derivation). * A simple approach to packaging NPM applications would be to split the package for an NPM application into two: - fetch: let NPM download all the dependencies. it should(?) be possible to make this a fixed-output derivation, as long as NPM downloads the same set of dependencies each time - build: use the cache from the fetch phase, should require no network access The fetch phase should be deterministic if we freeze the NPM index (is such a thing possible?) and use shrinkwrap. Or is this not the case? In what cases will it fail to be deterministic? * Alternatively, `yarn` claims to be more deterministic. Can we use `yarn` to build all NPM packages? Or are there NPM packages that are incompatible? I have read the articles from Sander van der Burg, but they don't seem to explain why we went with "one derivation per library", which requires us to manually symlink things into the node_modules folder. Kind regards, Benno
_______________________________________________ nix-dev mailing list nix-dev@lists.science.uu.nl https://mailman.science.uu.nl/mailman/listinfo/nix-dev