ci/version-info: correctly set NIX_PATH instead of flake registries

Flake registries and include paths are not the same thing.

`<nixpkgs>` looks for nixpkgs on the include path, set by `NIX_PATH` and
`--include`. However `--inputs-from` adds inputs to the flake registry,
not the include path.

(cherry picked from commit 2369b7fc4f)
This commit is contained in:
Matt Sturgeon 2025-07-07 16:48:10 +01:00
parent 13cc4d8457
commit f8b5a2fa7d

View file

@ -1,5 +1,6 @@
{
lib,
path,
callPackage,
writeShellApplication,
stdenv,
@ -15,6 +16,7 @@ writeShellApplication {
NIX_CONFIG = ''
experimental-features = nix-command flakes pipe-operators
'';
NIX_PATH = "nixpkgs=${toString path}";
};
text = ''
@ -23,7 +25,6 @@ writeShellApplication {
# Use channels.nix to build channels.toml
nix build --impure \
--inputs-from ${toString ../..} \
--file ${./supported-versions.nix} \
--argstr system ${stdenv.hostPlatform.system} \
--arg-from-file channelsJSON channels.json \