diff options
Diffstat (limited to 'modules/user/sternenseemann/services')
-rw-r--r-- | modules/user/sternenseemann/services/sway.nix | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/modules/user/sternenseemann/services/sway.nix b/modules/user/sternenseemann/services/sway.nix index 11048c49..e0f5eca3 100644 --- a/modules/user/sternenseemann/services/sway.nix +++ b/modules/user/sternenseemann/services/sway.nix @@ -132,6 +132,17 @@ in { Additional lines to append to the configuration. ''; }; + + extraStatus = lib.mkOption { + type = lib.types.attrsOf lib.types.lines; + default = {}; + description = "Additional i3status entries to prepend to the bar."; + example = { + "path_exists LOCK" = '' + path = "/run/lock" + ''; + }; + }; }; }; @@ -304,6 +315,13 @@ in { interval = 1 } + ${ + lib.concatStrings ( + lib.mapAttrsToList + (name: _: "order += \"${name}\"\n") + cfg.extraStatus + ) + } order += "volume master" order += "battery all" order += "tztime kalenderwoche" @@ -344,6 +362,17 @@ in { tztime offset { format = "%z" } + + ${ + lib.concatStrings ( + lib.mapAttrsToList (name: config: '' + ${name} { + ${builtins.replaceStrings [ "\n" ] [ "\n " ] config} + } + '' + ) cfg.extraStatus + ) + } ''; }; }; |