nix-installer icon indicating copy to clipboard operation
nix-installer copied to clipboard

Option to install only stable Nix version

Open srid opened this issue 1 year ago • 0 comments

This nix-installer always installs the latest Nix version. For those that just want stable Nix version (2.18 right now) matching pkgs.nix in nixpkgs (nixpkgs-unstable), it would be nice to have a single option that does that.

The current approach at https://github.com/DeterminateSystems/nix-installer?tab=readme-ov-file#accessing-other-versions however requires knowing the exact version of either the installer or Nix:

VERSION="v0.6.0"
curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix/tag/${VERSION} | sh -s -- install

or

NIX_INSTALLER_NIX_PACKAGE_URL=https://releases.nixos.org/nix/nix-2.18.1/nix-2.18.1-x86_64-linux.tar.xz
curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install

Instead, something like this would be desirable:

curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install --stable

Note: The --stable option at end.

srid avatar Sep 13 '24 16:09 srid