diff options
author | aszlig <aszlig@redmoonstudios.org> | 2014-08-04 04:13:11 +0200 |
---|---|---|
committer | aszlig <aszlig@redmoonstudios.org> | 2014-08-04 04:14:15 +0200 |
commit | da2c8a7cae5ebf0894c7835935bb43b989e45b5d (patch) | |
tree | 581bc504bd8e42bc3944f58da64bf6d60b0b4ae8 /modules/i3/default.nix | |
parent | 4489c5a4a024b51cb40d45a7a17ae6f556e61c0b (diff) |
i3: Apply reverseHeads option to bar config.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Diffstat (limited to 'modules/i3/default.nix')
-rw-r--r-- | modules/i3/default.nix | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/modules/i3/default.nix b/modules/i3/default.nix index 417e987a..68295270 100644 --- a/modules/i3/default.nix +++ b/modules/i3/default.nix @@ -39,7 +39,7 @@ let inherit pkgs; }; - mkBar = output: statusCmd: '' + mkBar = output: statusCmd: singleton '' bar { ${optionalString (output != null) "output ${output}"} ${optionalString (statusCmd != null) "status_command ${statusCmd}"} @@ -52,13 +52,15 @@ let } ''; - barConfig = - if headCount == 0 then mkBar null conky.single - else if headCount == 1 then mkBar (head xrandrHeads) conky.single - else let inner = take (length xrandrHeads - 2) (tail xrandrHeads); - in mkBar (head xrandrHeads) conky.left - + concatMapStrings (flip mkBar null) inner - + mkBar (last xrandrHeads) conky.right; + barConfig = let + bars = if headCount == 0 then mkBar null conky.single + else if headCount == 1 then mkBar (head xrandrHeads) conky.single + else let inner = take (length xrandrHeads - 2) (tail xrandrHeads); + in mkBar (head xrandrHeads) conky.left + ++ map (flip mkBar null) inner + ++ mkBar (last xrandrHeads) conky.right; + in concatStrings (headModifier bars); + in { options.vuizvui.i3 = { |