treewide: fix modules options types where the default is null

They can be caught with `nixos-option -r` on an empty ({...}:{}) NixOS
configuration.
This commit is contained in:
Thibaut Marty 2020-04-28 19:13:21 +02:00
parent 27c7e7d38a
commit 4a0beed5c0
9 changed files with 10 additions and 10 deletions

View File

@ -51,7 +51,7 @@ in
}; };
secretKeyFile = mkOption { secretKeyFile = mkOption {
type = types.path; type = types.nullOr types.path;
default = null; default = null;
description = '' description = ''
A file containing your secret key. The security of your Duo application is tied to the security of your secret key. A file containing your secret key. The security of your Duo application is tied to the security of your secret key.

View File

@ -47,7 +47,7 @@ in {
enable = mkEnableOption "Icecast server"; enable = mkEnableOption "Icecast server";
hostname = mkOption { hostname = mkOption {
type = types.str; type = types.nullOr types.str;
description = "DNS name or IP address that will be used for the stream directory lookups or possibily the playlist generation if a Host header is not provided."; description = "DNS name or IP address that will be used for the stream directory lookups or possibily the playlist generation if a Host header is not provided.";
default = config.networking.domain; default = config.networking.domain;
}; };

View File

@ -12,7 +12,7 @@ in{
config = mkOption { config = mkOption {
default = null; default = null;
type = types.lines; type = types.nullOr types.lines;
description = "Fancontrol configuration file content. See <citerefentry><refentrytitle>pwmconfig</refentrytitle><manvolnum>8</manvolnum></citerefentry> from the lm_sensors package."; description = "Fancontrol configuration file content. See <citerefentry><refentrytitle>pwmconfig</refentrytitle><manvolnum>8</manvolnum></citerefentry> from the lm_sensors package.";
example = '' example = ''
# Configuration file generated by pwmconfig # Configuration file generated by pwmconfig

View File

@ -172,7 +172,7 @@ in {
}; };
database = mkOption { database = mkOption {
type = types.str; type = types.nullOr types.str;
default = null; default = null;
description = "Database name to store sms data"; description = "Database name to store sms data";
}; };

View File

@ -83,14 +83,14 @@ in {
}; };
dataStorageSpace = mkOption { dataStorageSpace = mkOption {
type = types.str; type = types.nullOr types.str;
default = null; default = null;
example = "/data/storage"; example = "/data/storage";
description = "Directory for data storage."; description = "Directory for data storage.";
}; };
metadataStorageSpace = mkOption { metadataStorageSpace = mkOption {
type = types.str; type = types.nullOr types.str;
default = null; default = null;
example = "/data/meta"; example = "/data/meta";
description = "Directory for meta data storage."; description = "Directory for meta data storage.";

View File

@ -87,7 +87,7 @@ in
}; };
rpc.password = mkOption { rpc.password = mkOption {
type = types.str; type = types.nullOr types.str;
default = null; default = null;
description = '' description = ''
Password for RPC connections. Password for RPC connections.

View File

@ -89,7 +89,7 @@ in
}; };
rpc.password = mkOption { rpc.password = mkOption {
type = types.str; type = types.nullOr types.str;
default = null; default = null;
description = '' description = ''
Password for RPC connections. Password for RPC connections.

View File

@ -637,7 +637,7 @@ in
credential = mkOption { credential = mkOption {
default = null; default = null;
example = "f1d00200d8dc783f7fb1e10ace8da27f8312d72692abfca2f7e4960a73f48e82e1f7571f6ebfcee9fb434f9886ccc8fcc52a6614d8d2"; example = "f1d00200d8dc783f7fb1e10ace8da27f8312d72692abfca2f7e4960a73f48e82e1f7571f6ebfcee9fb434f9886ccc8fcc52a6614d8d2";
type = types.str; type = types.nullOr types.str;
description = "The FIDO2 credential ID."; description = "The FIDO2 credential ID.";
}; };

View File

@ -32,7 +32,7 @@ in
}; };
package = mkOption { package = mkOption {
type = types.package; type = types.nullOr types.package;
default = config.boot.kernelPackages.prl-tools; default = config.boot.kernelPackages.prl-tools;
defaultText = "config.boot.kernelPackages.prl-tools"; defaultText = "config.boot.kernelPackages.prl-tools";
example = literalExample "config.boot.kernelPackages.prl-tools"; example = literalExample "config.boot.kernelPackages.prl-tools";