diff --git a/pkgs/tools/package-management/nix/default.nix b/pkgs/tools/package-management/nix/default.nix index 35edaf2bef46..712055bfba29 100644 --- a/pkgs/tools/package-management/nix/default.nix +++ b/pkgs/tools/package-management/nix/default.nix @@ -115,7 +115,9 @@ let runCommand "test-nix-fallback-paths-version-equals-nix-stable" { paths = lib.concatStringsSep "\n" (builtins.attrValues (import ../../../../nixos/modules/installer/tools/nix-fallback-paths.nix)); } '' - if [[ "" != $(grep -v 'nix-${pkg.version}$' <<< "$paths") ]]; then + # NOTE: name may contain cross compilation details between the pname + # and version this is permitted thanks to ([^-]*-)* + if [[ "" != $(grep -vE 'nix-([^-]*-)*${lib.strings.replaceStrings ["."] ["\\."] pkg.version}$' <<< "$paths") ]]; then echo "nix-fallback-paths not up to date with nixVersions.stable (nix-${pkg.version})" echo "The following paths are not up to date:" grep -v 'nix-${pkg.version}$' <<< "$paths"