diff options
author | aszlig <aszlig@redmoonstudios.org> | 2014-08-27 23:41:15 +0200 |
---|---|---|
committer | aszlig <aszlig@redmoonstudios.org> | 2014-08-27 23:41:15 +0200 |
commit | 8a56a55bb442cbf2e2126d40df55e67b9aea0361 (patch) | |
tree | 916948eff016c868746d3a31b9e6f6120d33e449 /nixos/modules/config | |
parent | 9667a4067c7e3f02a6a0fe8f1f3344c1cb1d7ef7 (diff) |
nixos/manual: Use literalExample when feasible.
Should bring most of the examples into a better consistency regarding
syntactic representation in the manual.
Thanks to @devhell for reporting.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Diffstat (limited to 'nixos/modules/config')
-rw-r--r-- | nixos/modules/config/fonts/fonts.nix | 2 | ||||
-rw-r--r-- | nixos/modules/config/power-management.nix | 8 | ||||
-rw-r--r-- | nixos/modules/config/pulseaudio.nix | 2 | ||||
-rw-r--r-- | nixos/modules/config/shells-environment.nix | 4 |
4 files changed, 11 insertions, 5 deletions
diff --git a/nixos/modules/config/fonts/fonts.nix b/nixos/modules/config/fonts/fonts.nix index 49b1e1d42a3f..f6060a910a15 100644 --- a/nixos/modules/config/fonts/fonts.nix +++ b/nixos/modules/config/fonts/fonts.nix @@ -11,7 +11,7 @@ with lib; # TODO: find another name for it. fonts = mkOption { type = types.listOf types.path; - example = [ pkgs.dejavu_fonts ]; + example = literalExample "[ pkgs.dejavu_fonts ]"; description = "List of primary font paths."; apply = list: list ++ [ # - the user's current profile diff --git a/nixos/modules/config/power-management.nix b/nixos/modules/config/power-management.nix index 17f3ed00b9be..32a7987617ad 100644 --- a/nixos/modules/config/power-management.nix +++ b/nixos/modules/config/power-management.nix @@ -35,7 +35,9 @@ in powerUpCommands = mkOption { type = types.lines; default = ""; - example = "${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda"; + example = literalExample '' + "''${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda" + ''; description = '' Commands executed when the machine powers up. That is, @@ -47,7 +49,9 @@ in powerDownCommands = mkOption { type = types.lines; default = ""; - example = "${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda"; + example = literalExample '' + "''${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda" + ''; description = '' Commands executed when the machine powers down. That is, diff --git a/nixos/modules/config/pulseaudio.nix b/nixos/modules/config/pulseaudio.nix index 96593885e5b7..1b84bbaf10c5 100644 --- a/nixos/modules/config/pulseaudio.nix +++ b/nixos/modules/config/pulseaudio.nix @@ -81,7 +81,7 @@ in { package = mkOption { type = types.package; default = pulseaudioFull; - example = literalExample "pulseaudioFull"; + example = literalExample "pkgs.pulseaudioFull"; description = '' The PulseAudio derivation to use. This can be used to disable features (such as JACK support, Bluetooth) that are enabled in the diff --git a/nixos/modules/config/shells-environment.nix b/nixos/modules/config/shells-environment.nix index cc079cdc5856..2559c53ac163 100644 --- a/nixos/modules/config/shells-environment.nix +++ b/nixos/modules/config/shells-environment.nix @@ -122,7 +122,9 @@ in environment.binsh = mkOption { default = "${config.system.build.binsh}/bin/sh"; - example = "\${pkgs.dash}/bin/dash"; + example = literalExample '' + "''${pkgs.dash}/bin/dash" + ''; type = types.path; description = '' The shell executable that is linked system-wide to |