summary refs log tree commit diff
path: root/lib/options.nix
diff options
context:
space:
mode:
authorJan Malakhovski <oxij@oxij.org>2019-02-22 00:05:58 +0000
committerJan Malakhovski <oxij@oxij.org>2019-03-05 09:41:41 +0000
commita53b3ba091153de98b76e42d4a90607179bf64bf (patch)
treed15f0ccd4b6850476a83961b1fda1ae15138f6f2 /lib/options.nix
parentca496b194f7c16e252a8cd0f7e3942823defc5a0 (diff)
downloadnixpkgs-a53b3ba091153de98b76e42d4a90607179bf64bf.tar
nixpkgs-a53b3ba091153de98b76e42d4a90607179bf64bf.tar.gz
nixpkgs-a53b3ba091153de98b76e42d4a90607179bf64bf.tar.bz2
nixpkgs-a53b3ba091153de98b76e42d4a90607179bf64bf.tar.lz
nixpkgs-a53b3ba091153de98b76e42d4a90607179bf64bf.tar.xz
nixpkgs-a53b3ba091153de98b76e42d4a90607179bf64bf.tar.zst
nixpkgs-a53b3ba091153de98b76e42d4a90607179bf64bf.zip
lib: optionAttrSetToDocList: warn instead of throwing on options without descriptions
For convenience, it's not like not having a description is deadly or something.
Diffstat (limited to 'lib/options.nix')
-rw-r--r--lib/options.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/options.nix b/lib/options.nix
index 5cea99067aa..d46dec6e41c 100644
--- a/lib/options.nix
+++ b/lib/options.nix
@@ -141,7 +141,7 @@ rec {
         docOption = rec {
           loc = opt.loc;
           name = showOption opt.loc;
-          description = opt.description or (throw "Option `${name}' has no description.");
+          description = opt.description or (lib.warn "Option `${name}' has no description." "This option has no description.");
           declarations = filter (x: x != unknownModule) opt.declarations;
           internal = opt.internal or false;
           visible = opt.visible or true;