105 lines
2.5 KiB
Nix
105 lines
2.5 KiB
Nix
|
|
{ pkgs, ... }:
|
|||
|
|
let
|
|||
|
|
commands = import ../../../lib/commands.nix { inherit pkgs; };
|
|||
|
|
inherit (commands) uwsm term;
|
|||
|
|
in
|
|||
|
|
{
|
|||
|
|
programs.waybar = {
|
|||
|
|
enable = true;
|
|||
|
|
systemd = {
|
|||
|
|
enable = true;
|
|||
|
|
target = "graphical-session.target";
|
|||
|
|
};
|
|||
|
|
settings.mainBar = {
|
|||
|
|
layer = "bottom";
|
|||
|
|
position = "top";
|
|||
|
|
height = 28;
|
|||
|
|
spacing = 0;
|
|||
|
|
modules-left = [ "sway/workspaces" ];
|
|||
|
|
modules-center = [ "sway/window" ];
|
|||
|
|
modules-right = [
|
|||
|
|
"tray"
|
|||
|
|
"idle_inhibitor"
|
|||
|
|
"network"
|
|||
|
|
"bluetooth"
|
|||
|
|
"pulseaudio"
|
|||
|
|
"battery"
|
|||
|
|
"sway/language"
|
|||
|
|
"clock"
|
|||
|
|
];
|
|||
|
|
"sway/workspaces" = {
|
|||
|
|
on-click = "activate";
|
|||
|
|
sort-by-number = true;
|
|||
|
|
format = "{value}";
|
|||
|
|
};
|
|||
|
|
"sway/window".max-length = 64;
|
|||
|
|
tray = {
|
|||
|
|
icon-size = 24;
|
|||
|
|
spacing = 8;
|
|||
|
|
};
|
|||
|
|
idle_inhibitor = {
|
|||
|
|
format = "| {icon}";
|
|||
|
|
start-activated = true;
|
|||
|
|
format-icons = {
|
|||
|
|
activated = "🫨";
|
|||
|
|
deactivated = "😴";
|
|||
|
|
};
|
|||
|
|
};
|
|||
|
|
"sway/language" = {
|
|||
|
|
format = "| {flag}";
|
|||
|
|
tooltip-format = "{long}";
|
|||
|
|
};
|
|||
|
|
clock = {
|
|||
|
|
interval = 60;
|
|||
|
|
tooltip = true;
|
|||
|
|
format = "| {:%H:%M} ";
|
|||
|
|
tooltip-format = "{:%Y-%m-%d}";
|
|||
|
|
};
|
|||
|
|
battery = {
|
|||
|
|
interval = 60;
|
|||
|
|
format = "| {icon}{capacity}%";
|
|||
|
|
format-charging = "| {icon}⚡{capacity}%";
|
|||
|
|
format-plugged = "| {icon}🔌{capacity}%";
|
|||
|
|
states = {
|
|||
|
|
critical = 10;
|
|||
|
|
warning = 20;
|
|||
|
|
good = 100;
|
|||
|
|
full = 100;
|
|||
|
|
over = 101;
|
|||
|
|
};
|
|||
|
|
format-icons = [ "🪫" "🪫" "🔋" "🔋" "🔋" ];
|
|||
|
|
};
|
|||
|
|
network = {
|
|||
|
|
tooltip-format = "{ifname} = {ipaddr}/{cidr}";
|
|||
|
|
format-wifi = "| ᯤ";
|
|||
|
|
format-ethernet = "| ⇄";
|
|||
|
|
format-linked = "| 🔗";
|
|||
|
|
format-disconnected = "| ⛓️💥";
|
|||
|
|
interval = 15;
|
|||
|
|
on-click = "${uwsm} ${term} -e nmtui";
|
|||
|
|
};
|
|||
|
|
bluetooth = {
|
|||
|
|
format-connected = "| ᛒ";
|
|||
|
|
format-on = "| ᚧ";
|
|||
|
|
format-disabled = "";
|
|||
|
|
format-no-controller = "";
|
|||
|
|
interval = 15;
|
|||
|
|
on-click = "${uwsm} ${term} -e bluetui";
|
|||
|
|
};
|
|||
|
|
pulseaudio = {
|
|||
|
|
format = "| 🔊{volume}%";
|
|||
|
|
format-muted = "| 🔈0%";
|
|||
|
|
format-bluetooth = "| 🎧{volume}%";
|
|||
|
|
on-click = "${uwsm} pavucontrol";
|
|||
|
|
};
|
|||
|
|
};
|
|||
|
|
style = ''
|
|||
|
|
button {
|
|||
|
|
box-shadow: inset 0 -8px transparent;
|
|||
|
|
border: none;
|
|||
|
|
border-radius: 0;
|
|||
|
|
}
|
|||
|
|
'';
|
|||
|
|
};
|
|||
|
|
}
|