about summary refs log tree commit diff
path: root/lib
diff options
context:
space:
mode:
authorRobert Hensing <roberth@users.noreply.github.com>2023-05-11 17:34:46 +0200
committerGitHub <noreply@github.com>2023-05-11 17:34:46 +0200
commit5c3e59b6d6ab60cee1c3c404840f2a98f703e599 (patch)
tree6acb82071b4f8d8cac877f1f8e72fca6a4308143 /lib
parent4159685adfca8a710cf7826a314cc564ccd327b9 (diff)
parent16e3647337b4cacb8f9200d4e2dfbf2f0ba87a98 (diff)
Merge pull request #230523 from hercules-ci/fast-nixos-test-eval
Fast nixos test eval
Diffstat (limited to 'lib')
-rw-r--r--lib/types.nix8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/types.nix b/lib/types.nix
index e0da18a2febb9..373d0ce7876f9 100644
--- a/lib/types.nix
+++ b/lib/types.nix
@@ -476,6 +476,14 @@ rec {
       check = x: isDerivation x && hasAttr "shellPath" x;
     };
 
+    pkgs = addCheck
+      (unique { message = "A Nixpkgs pkgs set can not be merged with another pkgs set."; } attrs // {
+        name = "pkgs";
+        descriptionClass = "noun";
+        description = "Nixpkgs package set";
+      })
+      (x: (x._type or null) == "pkgs");
+
     path = mkOptionType {
       name = "path";
       descriptionClass = "noun";