about summary refs log tree commit diff
path: root/home/profiles/gui/config/waybar/settings.nix
blob: 1529378640fc18d91e298ef04a4a16ba5c633577 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
{ config, lib, neotheme }:

with neotheme.colors;

let
  guiCfg = config.profiles.gui;
in
{
  layer = "bottom";
  position = "top";
  height = 22;
  modules-left = [ "wireplumber" "custom/separator" "cpu" "custom/separator" "memory" "custom/separator" "idle_inhibitor" ];
  modules-center = [ "sway/workspaces" ];
  modules-right = [ "group/tray" "custom/separator" "network" "custom/separator" ]
    ++ lib.optionals (guiCfg.laptop.enable) [ "battery" "custom/separator" ]
    ++ [ "clock" ];

  "sway/workspaces" = {
    all-outputs = true;
    disable-scroll = false;
    format = "{name}";
    persistent-workspaces = {
      "1:I" = [ ];
      "2:II" = [ ];
      "3:III" = [ ];
      "4:IV" = [ ];
      "5:V" = [ ];
      "6:VI" = [ ];
      "7:VII" = [ ];
      "8:VIII" = [ ];
      "9:IX" = [ ];
      "10:X" = [ ];
    };
  };

  "clock" = {
    interval = 10;
    format = "<span foreground='#${color5}'>TIME</span> {:%A, %b %d %H:%M}";
  };

  "cpu" = {
    interval = 5;
    format = "<span foreground='#${color2}'>CPU</span> {usage:2}%";
  };

  "wireplumber" = {
    format = "<span foreground='#${color4}'>VOL</span> {volume}%";
    format-muted = "<span foreground='#${color4}'>VOL</span> Muted";
  };

  "memory" = {
    interval = 5;
    format = "<span foreground='#${color3}'>MEM</span> {used:0.2f}GiB";
  };

  "battery" = {
    format = "<span foreground='#${color6}'>BATT</span> {capacity}%";
    format-alt = "<span foreground='#${color6}'>PWR</span> {power}Wh";
  };

  "network" = {
    format = "<span foreground='#${color1}'>NET</span> {ifname}";
    format-wifi = "<span foreground='#${color1}'>NET</span> {essid} [{signalStrength}]";
    format-ethernet = "<span foreground='#${color1}'>NET</span> [ethernet]";
    format-linked = "<span foreground='#${color1}'>NET</span> {ifname} (No IP)";
    format-disconnected = "<span foreground='#${color1}'>NET</span> disconnected";
    tooltip-format = "{ifname} via {gwaddr}";
    tooltip-format-wifi = "{ipaddr}/{cidr} via {essid} ({signaldBm}dBm)";
    tooltip-format-ethernet = "{ipaddr}/{cidr} via Ethernet";
    tooltip-format-disconnected = "{ifname} Disconnected";
  };

  "idle_inhibitor" = {
    format = "<span foreground='#a89984'>CAFFEINE</span> {status}";
  };

  "group/tray" = {
    orientation = "inherit";
    drawer = {
      transition-duration = 500;
    };
    modules = [
      "custom/tray-placeholder"
      "tray"
    ];
  };

  "tray" = {
    spacing = 5;
  };

  "custom/tray-placeholder" = {
    format = "Tray >";
    interval = "once";
    tooltip = false;
  };

  "custom/separator" = {
    format = "|";
    interval = "once";
    tooltip = false;
  };
}