From 19b7452eff859608cd93bcd32034ffbf4ec456dd Mon Sep 17 00:00:00 2001 From: Thiago Kenji Okada Date: Mon, 1 Dec 2025 12:55:55 +0000 Subject: [PATCH] nixos-rebuild-ng: remove withNgSuffix option --- nixos/modules/installer/tools/tools.nix | 1 - nixos/tests/installer.nix | 1 - pkgs/by-name/ni/nixos-rebuild-ng/package.nix | 7 +------ pkgs/by-name/ni/nixos-rebuild-ng/tests/repl.nix | 2 +- pkgs/top-level/aliases.nix | 1 + 5 files changed, 3 insertions(+), 9 deletions(-) diff --git a/nixos/modules/installer/tools/tools.nix b/nixos/modules/installer/tools/tools.nix index 0a8942d64b6a..fa12f47489ff 100644 --- a/nixos/modules/installer/tools/tools.nix +++ b/nixos/modules/installer/tools/tools.nix @@ -70,7 +70,6 @@ let nixos-install = pkgs.nixos-install.override { }; nixos-rebuild-ng = pkgs.nixos-rebuild-ng.override { nix = config.nix.package; - withNgSuffix = false; withReexec = true; }; diff --git a/nixos/tests/installer.nix b/nixos/tests/installer.nix index d9df8f820ee7..ffd1680c5df8 100644 --- a/nixos/tests/installer.nix +++ b/nixos/tests/installer.nix @@ -727,7 +727,6 @@ let libxslt.bin nixos-artwork.wallpapers.simple-dark-gray-bottom (nixos-rebuild-ng.override { - withNgSuffix = false; withReexec = true; }) ntp diff --git a/pkgs/by-name/ni/nixos-rebuild-ng/package.nix b/pkgs/by-name/ni/nixos-rebuild-ng/package.nix index 33f52e0e1c68..95d17c3984f7 100644 --- a/pkgs/by-name/ni/nixos-rebuild-ng/package.nix +++ b/pkgs/by-name/ni/nixos-rebuild-ng/package.nix @@ -9,7 +9,6 @@ python3Packages, runCommand, scdoc, - withNgSuffix ? true, withReexec ? false, withShellFiles ? true, # Very long tmp dirs lead to "too long for Unix domain socket" @@ -22,7 +21,7 @@ nixos-rebuild-ng, }: let - executable = if withNgSuffix then "nixos-rebuild-ng" else "nixos-rebuild"; + executable = "nixos-rebuild"; in python3Packages.buildPythonApplication rec { pname = "nixos-rebuild-ng"; @@ -57,9 +56,6 @@ python3Packages.buildPythonApplication rec { --subst-var-by executable ${executable} \ --subst-var-by withReexec ${lib.boolToString withReexec} \ --subst-var-by withShellFiles ${lib.boolToString withShellFiles} - - substituteInPlace pyproject.toml \ - --replace-fail nixos-rebuild ${executable} ''; postInstall = lib.optionalString withShellFiles '' @@ -105,7 +101,6 @@ python3Packages.buildPythonApplication rec { tests = { with_reexec = nixos-rebuild-ng.override { withReexec = true; - withNgSuffix = false; }; with_nix_latest = nixos-rebuild-ng.override { nix = nixVersions.latest; diff --git a/pkgs/by-name/ni/nixos-rebuild-ng/tests/repl.nix b/pkgs/by-name/ni/nixos-rebuild-ng/tests/repl.nix index 1a614e8d8655..3408d95d2cdf 100644 --- a/pkgs/by-name/ni/nixos-rebuild-ng/tests/repl.nix +++ b/pkgs/by-name/ni/nixos-rebuild-ng/tests/repl.nix @@ -37,7 +37,7 @@ runCommand "test-nixos-rebuild-repl" nativeBuildInputs = [ expect nix - (nixos-rebuild-ng.override { withNgSuffix = false; }) + nixos-rebuild-ng ]; nixpkgs = if builtins.pathExists (path + "/.git") then lib.cleanSource path else path; diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index c6db26d29989..2741ca060094 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -1165,6 +1165,7 @@ mapAliases { else nixfmt; nixForLinking = throw "nixForLinking has been removed, use `nixVersions.nixComponents_` instead"; # Added 2025-08-14 + nixos-rebuild = nixos-rebuild-ng; # Added 2025-12-02 nixosTest = throw "'nixosTest' has been renamed to/replaced by 'testers.nixosTest'"; # Converted to throw 2025-10-27 nixStable = throw "'nixStable' has been renamed to/replaced by 'nixVersions.stable'"; # Converted to throw 2025-10-27 nm-tray = throw "'nm-tray' has been removed, as it only works with Plasma 5"; # Added 2025-08-30