Commit 4584a58c authored by Robert Hensing's avatar Robert Hensing Committed by Jörg Thalheim
Browse files

nix.stable.tests.nix-fallback-paths: Allow cross-compiled store path name

Nix 2.24 has a riscv5-linux path that's cross-compiled
e.g. nix-riscv64-unknown-linux-gnu-2.24.2
parent 5775c258
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -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"