diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2013-10-30 17:37:45 +0100 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2013-10-30 18:47:43 +0100 |
commit | 408b8b5725c3e6fff75aef772da248d3e95ff414 (patch) | |
tree | 692e3b61dbbff85cc97e3becf13a1376dea04a92 /nixos/modules/services/x11/display-managers | |
parent | d882e1966251880240599d3c1b31e060661506ee (diff) | |
download | nixpkgs-408b8b5725c3e6fff75aef772da248d3e95ff414.tar nixpkgs-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.gz nixpkgs-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.bz2 nixpkgs-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.lz nixpkgs-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.xz nixpkgs-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.zst nixpkgs-408b8b5725c3e6fff75aef772da248d3e95ff414.zip |
Add lots of missing option types
Diffstat (limited to 'nixos/modules/services/x11/display-managers')
-rw-r--r-- | nixos/modules/services/x11/display-managers/default.nix | 7 | ||||
-rw-r--r-- | nixos/modules/services/x11/display-managers/kdm.nix | 9 | ||||
-rw-r--r-- | nixos/modules/services/x11/display-managers/slim.nix | 19 |
3 files changed, 25 insertions, 10 deletions
diff --git a/nixos/modules/services/x11/display-managers/default.nix b/nixos/modules/services/x11/display-managers/default.nix index 0910708002b..c4fce3706dc 100644 --- a/nixos/modules/services/x11/display-managers/default.nix +++ b/nixos/modules/services/x11/display-managers/default.nix @@ -166,16 +166,19 @@ in services.xserver.displayManager = { xauthBin = mkOption { + internal = true; default = "${xorg.xauth}/bin/xauth"; description = "Path to the <command>xauth</command> program used by display managers."; }; xserverBin = mkOption { + type = types.path; default = "${xorg.xorgserver}/bin/X"; description = "Path to the X server used by display managers."; }; xserverArgs = mkOption { + type = types.listOf types.str; default = []; example = [ "-ac" "-logverbose" "-nolisten tcp" ]; description = "List of arguments for the X server."; @@ -183,16 +186,17 @@ in }; sessionCommands = mkOption { + type = types.lines; default = ""; example = '' xmessage "Hello World!" & ''; - type = types.string; description = "Shell commands executed just before the window or desktop manager is started."; }; desktopManagerHandlesLidAndPower = mkOption { + type = types.bool; default = true; description = '' Whether the display manager should prevent systemd from handling @@ -256,6 +260,7 @@ in }; environment = mkOption { + type = types.attrsOf types.unspecified; default = {}; example = { SLIM_CFGFILE = /etc/slim.conf; }; description = "Additional environment variables needed by the display manager."; diff --git a/nixos/modules/services/x11/display-managers/kdm.nix b/nixos/modules/services/x11/display-managers/kdm.nix index 2e84adcb4ce..c51e7edfddf 100644 --- a/nixos/modules/services/x11/display-managers/kdm.nix +++ b/nixos/modules/services/x11/display-managers/kdm.nix @@ -40,7 +40,7 @@ let [X-*-Greeter] HiddenUsers=root,nixbld1,nixbld2,nixbld3,nixbld4,nixbld5,nixbld6,nixbld7,nixbld8,nixbld9,nixbld10 PluginsLogin=${kdebase_workspace}/lib/kde4/kgreet_classic.so - ${optionalString (cfg.themeDirectory != "") + ${optionalString (cfg.themeDirectory != null) '' UseTheme=true Theme=${cfg.themeDirectory} @@ -78,6 +78,7 @@ in services.xserver.displayManager.kdm = { enable = mkOption { + type = types.bool; default = false; description = '' Whether to enable the KDE display manager. @@ -85,6 +86,7 @@ in }; enableXDMCP = mkOption { + type = types.bool; default = false; description = '' Whether to enable XDMCP, which allows remote logins. @@ -92,7 +94,8 @@ in }; themeDirectory = mkOption { - default = ""; + type = types.nullOr types.str; + default = null; description = '' The path to a KDM theme directory. This theme will be used by the KDM greeter. @@ -100,6 +103,7 @@ in }; setupScript = mkOption { + type = types.lines; default = ""; description = '' The path to a KDM setup script. This script is run as root just @@ -109,6 +113,7 @@ in }; extraConfig = mkOption { + type = types.lines; default = ""; description = '' Options appended to <filename>kdmrc</filename>, the diff --git a/nixos/modules/services/x11/display-managers/slim.nix b/nixos/modules/services/x11/display-managers/slim.nix index 01c9fa96c8c..35834ef3764 100644 --- a/nixos/modules/services/x11/display-managers/slim.nix +++ b/nixos/modules/services/x11/display-managers/slim.nix @@ -16,7 +16,7 @@ let login_cmd exec ${pkgs.stdenv.shell} ${dmcfg.session.script} "%session" halt_cmd ${config.systemd.package}/sbin/shutdown -h now reboot_cmd ${config.systemd.package}/sbin/shutdown -r now - ${optionalString (cfg.defaultUser != "") ("default_user " + cfg.defaultUser)} + ${optionalString (cfg.defaultUser != null) ("default_user " + cfg.defaultUser)} ${optionalString cfg.autoLogin "auto_login yes"} ''; @@ -45,6 +45,7 @@ in services.xserver.displayManager.slim = { enable = mkOption { + type = types.bool; default = config.services.xserver.enable; description = '' Whether to enable SLiM as the display manager. @@ -52,11 +53,14 @@ in }; theme = mkOption { + type = types.nullOr types.path; default = null; - example = pkgs.fetchurl { - url = http://download.berlios.de/slim/slim-wave.tar.gz; - sha256 = "0ndr419i5myzcylvxb89m9grl2xyq6fbnyc3lkd711mzlmnnfxdy"; - }; + example = literalExample '' + pkgs.fetchurl { + url = http://download.berlios.de/slim/slim-wave.tar.gz; + sha256 = "0ndr419i5myzcylvxb89m9grl2xyq6fbnyc3lkd711mzlmnnfxdy"; + } + ''; description = '' The theme for the SLiM login manager. If not specified, SLiM's default theme is used. See <link @@ -66,7 +70,8 @@ in }; defaultUser = mkOption { - default = ""; + type = types.nullOr types.str; + default = null; example = "login"; description = '' The default user to load. If you put a username here you @@ -76,8 +81,8 @@ in }; autoLogin = mkOption { + type = types.bool; default = false; - example = true; description = '' Automatically log in as the default user. ''; |