From 15da23d5c143dfa94543b120795af03b44dfbf0f Mon Sep 17 00:00:00 2001 From: Joachim Fasting Date: Tue, 7 Mar 2017 14:01:50 +0100 Subject: nixos/modules: use defaultText/literalExample where applicable Primarily to fix rendering of default values/examples but also to avoid unnecessary work. --- nixos/modules/services/cluster/kubernetes.nix | 1 + nixos/modules/services/continuous-integration/buildbot/master.nix | 5 +++-- nixos/modules/services/continuous-integration/buildbot/worker.nix | 5 +++-- nixos/modules/services/logging/fluentd.nix | 1 + nixos/modules/services/misc/ssm-agent.nix | 1 + nixos/modules/services/networking/searx.nix | 1 + nixos/modules/virtualisation/ecs-agent.nix | 1 + nixos/modules/virtualisation/openstack/glance.nix | 2 +- 8 files changed, 12 insertions(+), 5 deletions(-) (limited to 'nixos/modules') diff --git a/nixos/modules/services/cluster/kubernetes.nix b/nixos/modules/services/cluster/kubernetes.nix index a82802c3266..9ccc7295019 100644 --- a/nixos/modules/services/cluster/kubernetes.nix +++ b/nixos/modules/services/cluster/kubernetes.nix @@ -76,6 +76,7 @@ in { description = "Kubernetes package to use."; type = types.package; default = pkgs.kubernetes; + defaultText = "pkgs.kubernetes"; }; verbose = mkOption { diff --git a/nixos/modules/services/continuous-integration/buildbot/master.nix b/nixos/modules/services/continuous-integration/buildbot/master.nix index 68306109130..f363822c21c 100644 --- a/nixos/modules/services/continuous-integration/buildbot/master.nix +++ b/nixos/modules/services/continuous-integration/buildbot/master.nix @@ -180,13 +180,14 @@ in { package = mkOption { type = types.package; default = pkgs.buildbot-ui; + defaultText = "pkgs.buildbot-ui"; description = "Package to use for buildbot."; - example = pkgs.buildbot-full; + example = literalExample "pkgs.buildbot-full"; }; packages = mkOption { default = [ ]; - example = [ pkgs.git ]; + example = literalExample "[ pkgs.git ]"; type = types.listOf types.package; description = "Packages to add to PATH for the buildbot process."; }; diff --git a/nixos/modules/services/continuous-integration/buildbot/worker.nix b/nixos/modules/services/continuous-integration/buildbot/worker.nix index 1ad1319d501..e80869573fa 100644 --- a/nixos/modules/services/continuous-integration/buildbot/worker.nix +++ b/nixos/modules/services/continuous-integration/buildbot/worker.nix @@ -68,13 +68,14 @@ in { package = mkOption { type = types.package; default = pkgs.buildbot-worker; + defaultText = "pkgs.buildbot-worker"; description = "Package to use for buildbot worker."; - example = pkgs.buildbot-worker; + example = literalExample "pkgs.buildbot-worker"; }; packages = mkOption { default = [ ]; - example = [ pkgs.git ]; + example = literalExample "[ pkgs.git ]"; type = types.listOf types.package; description = "Packages to add to PATH for the buildbot process."; }; diff --git a/nixos/modules/services/logging/fluentd.nix b/nixos/modules/services/logging/fluentd.nix index e56a9a4e9af..9fbec245737 100644 --- a/nixos/modules/services/logging/fluentd.nix +++ b/nixos/modules/services/logging/fluentd.nix @@ -25,6 +25,7 @@ in { package = mkOption { type = types.path; default = pkgs.fluentd; + defaultText = "pkgs.fluentd"; description = "The fluentd package to use."; }; }; diff --git a/nixos/modules/services/misc/ssm-agent.nix b/nixos/modules/services/misc/ssm-agent.nix index b04959a9686..c1e1f090353 100644 --- a/nixos/modules/services/misc/ssm-agent.nix +++ b/nixos/modules/services/misc/ssm-agent.nix @@ -23,6 +23,7 @@ in { type = types.path; description = "The SSM agent package to use"; default = pkgs.ssm-agent; + defaultText = "pkgs.ssm-agent"; }; }; diff --git a/nixos/modules/services/networking/searx.nix b/nixos/modules/services/networking/searx.nix index bb0c2c485f2..3520c6d3f7d 100644 --- a/nixos/modules/services/networking/searx.nix +++ b/nixos/modules/services/networking/searx.nix @@ -39,6 +39,7 @@ in package = mkOption { type = types.package; default = pkgs.pythonPackages.searx; + defaultText = "pkgs.pythonPackages.searx"; description = "searx package to use."; }; diff --git a/nixos/modules/virtualisation/ecs-agent.nix b/nixos/modules/virtualisation/ecs-agent.nix index 18e45e0b845..fc51b159579 100644 --- a/nixos/modules/virtualisation/ecs-agent.nix +++ b/nixos/modules/virtualisation/ecs-agent.nix @@ -12,6 +12,7 @@ in { type = types.path; description = "The ECS agent package to use"; default = pkgs.ecs-agent; + defaultText = "pkgs.ecs-agent"; }; extra-environment = mkOption { diff --git a/nixos/modules/virtualisation/openstack/glance.nix b/nixos/modules/virtualisation/openstack/glance.nix index 4d85718e369..7862409a65e 100644 --- a/nixos/modules/virtualisation/openstack/glance.nix +++ b/nixos/modules/virtualisation/openstack/glance.nix @@ -43,7 +43,7 @@ in { package = mkOption { type = types.package; default = pkgs.glance; - example = literalExample "pkgs.glance"; + defaultText = "pkgs.glance"; description = '' Glance package to use. ''; -- cgit 1.4.1