Auto-adapts sway workspace routing to however many monitors are connected (laptop vs. desktop) instead of hardcoding output names.
29 lines
1.8 KiB
JSON
29 lines
1.8 KiB
JSON
{
|
|
"layer": "top",
|
|
"position": "top",
|
|
"height": 32,
|
|
"spacing": 6,
|
|
"modules-left": ["sway/workspaces", "sway/mode"],
|
|
"modules-center": ["clock"],
|
|
"modules-right": ["cpu", "memory", "custom/network", "pulseaudio", "backlight", "battery", "tray", "custom/power"],
|
|
"sway/workspaces": {
|
|
"disable-scroll": false,
|
|
"all-outputs": false,
|
|
"on-click-right": "~/.config/waybar/scripts/rename-workspace.sh"
|
|
},
|
|
"clock": { "format": "{:%a %d %b %H:%M}", "tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>" },
|
|
"cpu": { "format": "CPU {usage}%", "tooltip": true, "on-click": "kitty --class system-monitor --title 'System Monitor' btop" },
|
|
"memory": { "format": "RAM {percentage}%", "tooltip-format": "{used:0.1f} GiB used", "on-click": "kitty --class system-monitor --title 'System Monitor' btop" },
|
|
"custom/network": { "exec": "~/.config/waybar/scripts/network-cycle.sh", "return-type": "json", "interval": 300, "signal": 8, "on-click": "~/.config/waybar/scripts/network-cycle.sh next", "on-click-right": "~/.config/waybar/scripts/network-cycle.sh copy" },
|
|
"pulseaudio": { "format": "{icon} {volume}%", "format-muted": " muted", "format-icons": ["", "", ""], "tooltip-format": "{desc}", "on-click": "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle", "on-click-right": "~/.config/waybar/scripts/audio-output-cycle.sh" },
|
|
"backlight": { "format": " {percent}%" },
|
|
"battery": { "states": { "warning": 30, "critical": 15 }, "format": "{icon} {capacity}%", "format-charging": " {capacity}%", "format-icons": ["", "", "", "", ""] },
|
|
"tray": { "spacing": 8 },
|
|
"custom/power": {
|
|
"format": "",
|
|
"tooltip": true,
|
|
"tooltip-format": "Power menu",
|
|
"on-click": "~/.config/waybar/scripts/power-menu.sh"
|
|
}
|
|
}
|