Hi! I was excited to see the release announcement for Nix 2.4, but I do not understand how to install it via
configuration.nix. What is the one true way to do it?
Here is what I’ve gathered so far:
This comment says that Nix 2.4 is available in nixpkgs-unstable, but I don’t know how (or if I even should) expose nixpkgs-unstable to my
- I can run Nix 2.4 via its flake, like so:
nix run github:nixos/nix/2.4, but this is quite different from installing it systemwide.
- I can use
builtins.getFlaketo install the Nix 2.4 flake via
home-manager, but that doesn’t seem like a good idea–or rather, it does not solve my ultimate problem, which is that I would like a systemwide installation.
- I cannot use
builtins.getFlaketo install that flake in my system configuration, because
getFlakeis supplied by experimental Nix (i.e. it’s a chicken-and-egg problem, I think).
This seems like a simple thing to accomplish, so perhaps I’ve just missed the documentation for how to do this. The announcement links to an installation help page that says to pipe
sh, but that’s a quickstart kind of thing that I’m obviously trying to avoid.
Thanks for any help on this!