diff options
Diffstat (limited to 'users/grfn')
-rw-r--r-- | users/grfn/system/home/machines/ogopogo.nix | 1 | ||||
-rw-r--r-- | users/grfn/system/home/modules/i3.nix | 34 |
2 files changed, 23 insertions, 12 deletions
diff --git a/users/grfn/system/home/machines/ogopogo.nix b/users/grfn/system/home/machines/ogopogo.nix index 19d3a5467265..e4144e79806e 100644 --- a/users/grfn/system/home/machines/ogopogo.nix +++ b/users/grfn/system/home/machines/ogopogo.nix @@ -20,6 +20,7 @@ in system.machine = { wirelessInterface = "wlp4s0"; i3FontSize = 9; + battery = false; }; home.packages = with pkgs; [ diff --git a/users/grfn/system/home/modules/i3.nix b/users/grfn/system/home/modules/i3.nix index c6e198c98a31..c9e485006b05 100644 --- a/users/grfn/system/home/modules/i3.nix +++ b/users/grfn/system/home/modules/i3.nix @@ -23,18 +23,26 @@ let in { options = with lib; { - system.machine.wirelessInterface = mkOption { - description = '' - Name of the primary wireless interface. Used by i3status, etc. - ''; - default = "wlp3s0"; - type = types.str; - }; + system.machine = { + wirelessInterface = mkOption { + description = '' + Name of the primary wireless interface. Used by i3status, etc. + ''; + default = "wlp3s0"; + type = types.str; + }; - system.machine.i3FontSize = mkOption { - description = "Font size to use in i3 window decorations etc."; - default = 6; - type = types.int; + i3FontSize = mkOption { + description = "Font size to use in i3 window decorations etc."; + default = 6; + type = types.int; + }; + + battery = mkOption { + description = "Does this system have a battery?"; + default = true; + type = types.bool; + }; }; }; @@ -231,7 +239,9 @@ in order += "wireless ${config.system.machine.wirelessInterface}" # order += "ethernet enp3s0f0" order += "cpu_usage" - order += "battery 0" + ${lib.optionalString (config.system.machine.battery) '' + order += "battery 0" + ''} # order += "volume master" order += "time" order += "tztime utc" |