diff options
author | sternenseemann <sternenseemann@systemli.org> | 2023-02-02 14:15:25 +0100 |
---|---|---|
committer | sternenseemann <sternenseemann@systemli.org> | 2023-02-02 14:17:06 +0100 |
commit | 33f4a858d5e2afc218f2975aaa64f24f4155f2d3 (patch) | |
tree | 447b8b3c7f500a45119cdf207ba32017c762b29c /modules/user/sternenseemann/services/sway.nix | |
parent | 2cafbd7e6881732e64477e11f4e0a1884e89f730 (diff) |
machines/sternenseemann/wolfgang: display state of wireguard ifaces
Diffstat (limited to 'modules/user/sternenseemann/services/sway.nix')
-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 + ) + } ''; }; }; |