
Move all the nixos-* scripts from the nixos distribution as real packages in the pkgs/ package set. This allows non-nixos users to run the script as well. For example, deploying a remote machine with: nixos-rebuild --target-host root@hostname --build-host root@hostname
14 lines
281 B
Nix
14 lines
281 B
Nix
{ substituteAll
|
|
, lib
|
|
, version ? lib.trivial.version
|
|
, codeName ? "unknown"
|
|
, revision ? lib.trivial.revisionWithDefault "master"
|
|
}:
|
|
substituteAll {
|
|
name = "nixos-version";
|
|
dir = "bin";
|
|
isExecutable = true;
|
|
src = ./nixos-version.sh;
|
|
inherit version codeName revision;
|
|
}
|