3 ms·
> Because Nix is a functional package manager... I'd explain "functional package manager" as "package manager where packages are declared as a function of thei
by rgoulter 4y ago
> Because Nix is a functional package manager...
I'd explain "functional package manager" as "package manager where packages are declared as a function of their inputs".
e.g. a package's inputs would be the compiler used to build it, and the source code.
One motivation for doing this is ensuring that a package's behaviour is reproducible.
There are all sorts of neat benefits this ends up allowing.
- bogwog 4y agoWhile not designed to be a system package manager, Conan works in a very similar way for C/C++ package management, and it's great. All binary packages live in the cache folder, identified by a hash of the particular permutation of inputs used to build it. It even supports recipe revisions, so if the recipe (build script) changes, you don't have to worry about changes in the generated binary since you can use a lock file to keep using the specific revision of that build script that you know works.
- pxc 4y agopnpm for Node packages also has a similar design. Once upon a time, it cited Nix as a source of inspiration in its docs! I hope that basic design continues to propagate. Better-behaved package management for language ecosystems is easier to work with for Linux distros, including NixOS. :)