summary refs log tree commit diff
path: root/nixos/default.nix
diff options
context:
space:
mode:
authorThomas Strobel <ts468@cam.ac.uk>2016-02-20 01:47:01 +0100
committerThomas Strobel <ts468@cam.ac.uk>2016-02-29 01:09:00 +0100
commitcad8957eabcbf73062226d28366fd446c15c8737 (patch)
tree0299e96391c14f612e7bd1cf3b2274198425fd61 /nixos/default.nix
parentc483224c82c8e94324c03576e64c5dfbf16bd2f8 (diff)
downloadnixpkgs-cad8957eabcbf73062226d28366fd446c15c8737.tar
nixpkgs-cad8957eabcbf73062226d28366fd446c15c8737.tar.gz
nixpkgs-cad8957eabcbf73062226d28366fd446c15c8737.tar.bz2
nixpkgs-cad8957eabcbf73062226d28366fd446c15c8737.tar.lz
nixpkgs-cad8957eabcbf73062226d28366fd446c15c8737.tar.xz
nixpkgs-cad8957eabcbf73062226d28366fd446c15c8737.tar.zst
nixpkgs-cad8957eabcbf73062226d28366fd446c15c8737.zip
Add the tool "nixos-typecheck" that can check an option declaration to:
 - Enforce that an option declaration has a "defaultText" if and only if the
   type of the option derives from "package", "packageSet" or "nixpkgsConfig"
   and if a "default" attribute is defined.

 - Enforce that the value of the "example" attribute is wrapped with "literalExample"
   if the type of the option derives from "package", "packageSet" or "nixpkgsConfig".

 - Warn if a "defaultText" is defined in an option declaration if the type of
   the option does not derive from "package", "packageSet" or "nixpkgsConfig".

 - Warn if no "type" is defined in an option declaration.
Diffstat (limited to 'nixos/default.nix')
-rw-r--r--nixos/default.nix2
1 files changed, 2 insertions, 0 deletions
diff --git a/nixos/default.nix b/nixos/default.nix
index 5d69b79e13a..117a7b5d603 100644
--- a/nixos/default.nix
+++ b/nixos/default.nix
@@ -34,6 +34,8 @@ in
 
   system = eval.config.system.build.toplevel;
 
+  typechecker = eval.config.system.build.typechecker;
+
   vm = vmConfig.system.build.vm;
 
   vmWithBootLoader = vmWithBootLoaderConfig.system.build.vm;