Is there a reasonable way to get Nix 2.4 installed today using nix-darwin (which manages system packages and therefore Nix itself)? It looks like it’s not even in nixpkgs yet (see nix: 2.3.16 -> 2.4 by lovesegfault · Pull Request #144197 · NixOS/nixpkgs · GitHub), let alone in the nixpkgs-unstable
channel.
Alternatively, how close is nix-2.4pre-rc1 to the actual released version? That’s what I see as the value of nix_2_4
right now. Is it reasonable to just install that today? I can look at the differing commits (Comparing 2.4pre-rc1...2.4 · NixOS/nix · GitHub) but I’m not sure if any of these are particularly important for standard usage.
2 Likes
I want to do exactly that except on NixOS. I am currently using a custom branch of Nixpkgs with the PR in it as an input to my system flake and pulling nix_2_4
from it with an overlay. I’ll tell in a few how that worked out. Even without flakes, a custom overlay might do. Either way expect to compile it yourself.
I believe the Chapter on overlays in the manual was recently greatly improved, so I’ll link it for anyone who might find it useful.
https://nixos.org/manual/nixpkgs/stable/#chap-overlays
1 Like
I was hoping for a solution that didn’t involve “compile Nix yourself”
I certainly can do that, but then I have to remember to remove that in a few days once Nix 2.4 is available in nixpkgs-unstable.
2 Likes
nix-2.4pre-rc1
is pretty close, the final 2.4 just has a few minor bug fixes. Alternatively you can get the binary for x86_64-darwin
from the binary cache`:
nix-store -r /nix/store/c3mvzszvyzakvcp9spnjvsb8m2bpjk7m-nix-2.4
3 Likes
It looks like nix_2_4
in nixpkgs-unstable is now the official Nix 2.4 release.