1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2025-03-05 16:27:03 +00:00

default.nix: Use nixpkgs.rev if it is set

This increases the odds of automatically setting system.nixpkgsRevision,
which makes the links in the manual nice.
This commit is contained in:
Robert Hensing 2023-06-30 02:13:09 +02:00
parent 25ae710ba3
commit d207fa6091

View file

@ -10,10 +10,15 @@ let
eval = evalConfig { eval = evalConfig {
inherit system; inherit system;
modules = [ configuration ]; modules = [ configuration nixpkgsRevisionModule ];
inputs = { inherit nixpkgs; }; inputs = { inherit nixpkgs; };
}; };
nixpkgsRevisionModule =
if nixpkgs?rev && lib.isString nixpkgs.rev
then { system.nixpkgsRevision = nixpkgs.rev; }
else { };
# The source code of this repo needed by the [un]installers. # The source code of this repo needed by the [un]installers.
nix-darwin = lib.cleanSource ( nix-darwin = lib.cleanSource (
lib.cleanSourceWith { lib.cleanSourceWith {