dotfiles/sway/waybar/config

182 lines
5.1 KiB
Plaintext
Raw Permalink Normal View History

2024-05-14 12:29:49 +03:00
{
"layer": "top", // Waybar at top layer
"position": "top", // Waybar position (top|bottom|left|right)
"height": 30,
"margin": "0 0 0 0",
//"width": 1350, // Waybar width
// Choose the order of the modules idle_inhibitor
"modules-left": [
"custom/launcher",
"sway/workspaces",
"tray",
"sway/mode",
],
"modules-center": ["clock"],
"modules-right": [
"backlight",
"pulseaudio",
"custom/keyboard-layout",
"temperature",
//"cpu",
2024-05-14 12:29:49 +03:00
"memory",
"battery",
"network",
"custom/power"
],
// Modules configuration
"sway/workspaces": {
"disable-scroll": true,
"all-outputs": true,
"format": "{icon}",
// "format": "< %g >",
2024-05-24 15:14:12 +03:00
//"format_focused" : "< %g ● >",
2024-05-14 12:29:49 +03:00
"format-icons": {
"1": "",
"2": "", //
2024-05-24 15:14:12 +03:00
"3": "", //
2024-05-14 12:29:49 +03:00
"4": "",
"5": "",
"6": "",
"7": "",
"8": "",
"9": "",
"10": ""
}
},
"sway/mode": {
"format": "<span style=\"italic\">{}</span>"
},
"sway/window": {
"format": "~ {app_id}"
},
"idle_inhibitor": {
"format": "{icon}",
"format-icons": {
"activated": "",
"deactivated": ""
}
},
"tray": {
2024-05-24 15:14:12 +03:00
"icon-size": 16,
"spacing": 6
2024-05-14 12:29:49 +03:00
},
"clock": {
"tooltip-format": "<tt><small>{calendar}</small></tt>",
"calendar": {
"mode": "month",
"mode-mon-col": 3,
"weeks-pos": "right",
"on-scroll": 1,
"on-click-right": "mode",
"format": {
"months": "<span color='#ffead3'><b>{}</b></span>",
"days": "<span color='#ecc6d9'><b>{}</b></span>",
"weeks": "<span color='#99ffdd'><b>W{}</b></span>",
"weekdays": "<span color='#ffcc66'><b>{}</b></span>",
"today": "<span color='#ff6699'><b><u>{}</u></b></span>"
}
},
"actions": {
"on-click-right": "mode",
"on-click-forward": "tz_up",
"on-click-backward": "tz_down",
"on-scroll-up": "shift_up",
"on-scroll-down": "shift_down"
},
//"format": " {:%a %d %b  %I:%M %p}", //12 hour format
2024-05-24 15:14:12 +03:00
"format": " {:%d.%m.%Y  %H:%M}", //24 hour format
2024-05-14 12:29:49 +03:00
"format-alt": " {:%d/%m/%Y  %H:%M:%S}",
// //"timezones": [ "Kolkata" ],
// //"max-length": 200
"interval": 1
},
"cpu": {
"interval": 10,
"format": " {}%",
"max-length": 4,
2024-05-14 12:29:49 +03:00
"on-click": "foot -e btop"
},
"memory": {
2024-05-24 15:14:12 +03:00
"format": "󰍛{: >3}%",
2024-05-14 12:29:49 +03:00
"on-click": "foot -e btop"
},
"temperature": {
// "thermal-zone": 2,
"hwmon-path": "/sys/class/hwmon/hwmon0/temp1_input",
"critical-threshold": 80,
// "format-critical": "{temperatureC}°C ",
2024-05-24 15:14:12 +03:00
"format": " {temperatureC}°C"
2024-05-14 12:29:49 +03:00
},
"backlight": {
// "device": "acpi_video1",
"format": "{icon} {percent: >3}%",
"format-icons": ["", ""],
// "on-scroll-down": "brightnessctl -c backlight set 5%-",
"on-scroll-down": "light -A 1 && light -G | cut -d'.' -f1 > $SWAYSOCK.wob",
// "on-scroll-up": "brightnessctl -c backlight set +5%"
"on-scroll-up": "light -U 1 && light -G | cut -d'.' -f1 > $SWAYSOCK.wob"
},
"battery": {
"states": {
// "good": 95,
2024-05-24 15:14:12 +03:00
"warning": 45,
2024-05-14 12:29:49 +03:00
"critical": 15
},
"format": "{icon} {capacity: >3}%",
// "format-good": "", // An empty format will hide the module
// "format-full": "",
"format-icons": ["", "", "", "", ""]
//"format-icons": ["", "", "", "", "", "", "", "", "", ""]
},
"network": {
// "interface": "wlp2s0", // (Optional) To force the use of this interface
"format": "⚠ Disabled",
"format-wifi": " {essid}",
// "format-ethernet": " {ifname}: {ipaddr}/{cidr}",
"format-ethernet": " Wired",
"format-disconnected": "⚠ Disconnected",
// "on-click": "alacritty -e nmtui"
"on-click": "nm-connection-editor"
},
"pulseaudio": {
"scroll-step": 1,
"format": "{icon} {volume: >3}%",
"format-bluetooth": "{icon} {volume: >3}%",
"format-muted": " muted",
"format-icons": {
"headphones": "",
"handsfree": "",
"headset": "",
"phone": "",
"portable": "",
"car": "",
"default": ["", ""]
},
"on-click": "pavucontrol",
2024-05-24 15:14:12 +03:00
"on-scroll-up": "pamixer -ud 2 && pamixer --get-volume > $SWAYSOCK.wob",
"on-scroll-down": "pamixer -ui 2 && pamixer --get-volume > $SWAYSOCK.wob"
2024-05-14 12:29:49 +03:00
},
"custom/power": {
"format": "󰐥",
"on-click": "nwgbar -layer-shell-layer OVERLAY -layer-shell-exclusive-zone -1 -b 24273a -o 0.8",
2024-05-14 12:29:49 +03:00
"tooltip": false
},
"custom/keyboard-layout": {
"exec": "swaymsg -t get_inputs | grep -m1 'xkb_active_layout_name' | cut -d '\"' -f4",
// Interval set only as a fallback, as the value is updated by signal
"interval": 1,
"format": " {}", // Icon: keyboard
// Signal sent by Sway key binding (~/.config/sway/key-bindings)
"signal": 1, // SIGHUP
"tooltip": false,
"on-click": "~/.config/sway/waybar/scripts/keyhint.sh"
},
"custom/launcher": {
"format": " ",
"on-click": "exec nwg-drawer -c 7 -is 70 -spacing 23 -ovl",
2024-05-14 12:29:49 +03:00
"tooltip": false
}
}