Files
configs/.config/waybar/config.jsonc
2026-04-21 21:38:35 +02:00

122 lines
6.3 KiB
JSON

// -*- mode: jsonc -*-
{
"height": 30,
"spacing": 4,
"modules-left": [
"hyprland/workspaces",
"hyprland/window"
],
"modules-center": [
"clock"
],
"modules-right": [
"custom/spotify",
"custom/weather",
"custom/screenshot",
"idle_inhibitor",
"pulseaudio",
"network",
"custom/mount-data",
"custom/mount-usb1",
"cpu",
"tray"
],
"hyprland/workspaces": {
"format": "{id}"
},
"custom/screenshot": {
"exec": "printf '{\"text\": \"<span font_desc=\\\"SauceCodePro Nerd Font 14\\\" foreground=\\\"#FFFFFF\\\">󰄀</span> <span foreground=\\\"#E5E9F0\\\">Shot</span>\", \"tooltip\": \"Area screenshot: edit in Swappy, then choose save path and filename; Esc on filename uses screenshot\"}'",
"return-type": "json",
"escape": false,
"interval": "once",
"on-click": "$HOME/.config/waybar/scripts/capture-share-shot.sh"
},
"idle_inhibitor": {
"escape": false,
"format": "{icon}",
"format-icons": {
"activated": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#A3BE8C\"> </span><span foreground=\"#A3BE8C\">Awake</span>",
"deactivated": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#81A1C1\"> </span><span foreground=\"#D8DEE9\">Idle</span>"
}
},
"tray": {
"spacing": 10
},
"clock": {
"escape": false,
"format": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#88C0D0\"></span> <span foreground=\"#D8DEE9\">{:%H:%M}</span>",
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>",
"format-alt": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#81A1C1\"></span> <span foreground=\"#D8DEE9\">{:%Y-%m-%d}</span>"
},
"custom/spotify": {
"exec": "bash $HOME/.config/waybar/scripts/spotify-waybar.sh",
"return-type": "json",
"interval": 2,
"escape": false,
"on-click": "bash $HOME/.config/waybar/scripts/spotify-waybar.sh --toggle",
"on-click-right": "bash $HOME/.config/waybar/scripts/spotify-waybar.sh --stop",
"on-scroll-up": "bash $HOME/.config/waybar/scripts/spotify-waybar.sh --next",
"on-scroll-down": "bash $HOME/.config/waybar/scripts/spotify-waybar.sh --prev",
"tooltip": false
},
"custom/weather": {
"exec": "bash $HOME/.config/waybar/scripts/weather-norrkoping.sh",
"return-type": "json",
"interval": 600,
"escape": false,
"tooltip": true
},
"cpu": {
"escape": false,
"format": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#81A1C1\"></span> <span foreground=\"#D8DEE9\">{usage}%</span>",
"tooltip": false,
"on-click": "alacritty -e btop"
},
"custom/mount-data": {
"exec": "$HOME/.config/waybar/scripts/check-mount.sh /mnt/data data",
"return-type": "json",
"escape": false,
"interval": 10,
"tooltip": true,
"on-click": "thunar /mnt/data"
},
"custom/mount-usb1": {
"exec": "$HOME/.config/waybar/scripts/check-mount.sh /mnt/usb1 usb1",
"return-type": "json",
"escape": false,
"interval": 10,
"tooltip": true,
"on-click": "thunar /mnt/usb1"
},
"network": {
"escape": false,
"format-wifi": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#88C0D0\"> </span><span foreground=\"#D8DEE9\">{essid} ({signalStrength}%)</span>",
"format-ethernet": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#88C0D0\">󰈀 </span><span foreground=\"#D8DEE9\">{ipaddr}/{cidr}</span>",
"tooltip-format": "<span foreground=\"#D8DEE9\">{ifname} via {gwaddr}</span> <span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#88C0D0\">󰈀</span>",
"format-linked": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#81A1C1\">󰈀 </span><span foreground=\"#D8DEE9\">{ifname} (No IP)</span>",
"format-disconnected": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#BF616A\">󰖪 </span><span foreground=\"#EBCB8B\">Disconnected</span>",
"format-alt": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#88C0D0\">󰈀 </span><span foreground=\"#D8DEE9\">{ifname}: {ipaddr}/{cidr}</span>",
"on-click-right": "nm-connection-editor"
},
"pulseaudio": {
"escape": false,
"format": "{icon} {format_source} <span foreground=\"#D8DEE9\">{volume}%</span>",
"format-bluetooth": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#81A1C1\"></span> {icon} {format_source} <span foreground=\"#D8DEE9\">{volume}%</span>",
"format-bluetooth-muted": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#D08770\"></span> <span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#81A1C1\"></span> {icon} {format_source}",
"format-muted": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#D08770\"></span> {format_source}",
"format-source": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span> <span foreground=\"#D8DEE9\">{volume}%</span>",
"format-source-muted": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#D08770\"></span>",
"format-icons": {
"headphone": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>",
"hands-free": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>",
"headset": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>",
"phone": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>",
"portable": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>",
"car": "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>",
"default": ["<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>", "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>", "<span font_desc=\"SauceCodePro Nerd Font 14\" foreground=\"#B48EAD\"></span>"]
},
"on-click": "pavucontrol"
}
}