Moved clock to top

This commit is contained in:
Tibo De Peuter 2022-05-25 10:49:26 +02:00
parent 6295d6d98f
commit ccdd28178e

View file

@ -3,111 +3,113 @@
// //
[{ [{
"position": "bottom", // Waybar position (top|bottom|left|right) "position": "bottom",
"height": 30, "height": 30,
"spacing": 4, "spacing": 4,
"modules-left": ["sway/workspaces", "custom/media"], "modules-left": ["sway/workspaces", "custom/media"],
"modules-right": ["idle_inhibitor", "cpu", "memory", "disk", "temperature", "pulseaudio", "battery", "clock", "tray"], "modules-right": ["idle_inhibitor", "cpu", "memory", "disk", "temperature", "pulseaudio", "battery", "tray"],
"ipc": true, "ipc": true,
"sway/workspaces": { "sway/workspaces": {
"disable-scroll": true, "disable-scroll": true,
"all-outputs": true, "all-outputs": true,
"format": "{icon}{name}", "format": "{icon}{name}",
"format-icons": { "format-icons": {
"urgent": " ", "urgent": " ",
"default": "" // Prevent showing workspace name literal. "default": "" // Prevent showing workspace name literal.
}, },
}, },
"custom/media": { "custom/media": {
"format": "{icon} {}", "format": "{icon} {}",
"return-type": "json", "return-type": "json",
"max-length": 40, "max-length": 40,
"format-icons": { "format-icons": {
"spotify": "", "spotify": "",
"default": "🎜" "default": "🎜"
}, },
"escape": true, "escape": true,
"exec": "~/.config/waybar/mediaplayer.py 2> /dev/null", // Script in resources folder "exec": "~/.config/waybar/mediaplayer.py 2> /dev/null", // Script in resources folder
}, },
"idle_inhibitor": { "idle_inhibitor": {
"format": "Prohibit idle {icon}", "format": "Prohibit idle {icon}",
"format-icons": { "format-icons": {
"activated": "", "activated": "",
"deactivated": "" "deactivated": ""
}, },
"tooltip": false, "tooltip": false,
}, },
"cpu": { "cpu": {
"format": "{usage}% ", "format": "{usage}% ",
"tooltip": true, "tooltip": true,
}, },
"memory": { "memory": {
"format": "{}% ", "format": "{}% ",
}, },
"disk": { "disk": {
"interval": 30, "interval": 30,
"format": "{percentage_free}% ({free}) 💾", "format": "{percentage_free}% ({free}) 💾",
"path": "/", "path": "/",
}, },
"temperature": { "temperature": {
"critical-threshold": 70, "critical-threshold": 70,
// "format-critical": "{temperatureC}°C {icon}", // "format-critical": "{temperatureC}°C {icon}",
"format": "{temperatureC}°C {icon}", "format": "{temperatureC}°C {icon}",
"format-icons": ["", "", ""], "format-icons": ["", "", ""],
}, },
"pulseaudio": { "pulseaudio": {
"scroll-step": 2, "scroll-step": 2,
"format": "{volume}% {icon} {format_source}", "format": "{volume}% {icon} {format_source}",
"format-bluetooth": "{volume}% {icon} {format_source}", "format-bluetooth": "{volume}% {icon} {format_source}",
"format-bluetooth-muted": " {icon} {format_source}", "format-bluetooth-muted": " {icon} {format_source}",
"format-muted": " {format_source}", "format-muted": " {format_source}",
"format-source": "{volume}% ", "format-source": "{volume}% ",
"format-source-muted": "", "format-source-muted": "",
"format-icons": { "format-icons": {
"headphone": " ", "headphone": " ",
"hands-free": "", "hands-free": "",
"headset": "", "headset": "",
"phone": "", "phone": "",
"portable": "", "portable": "",
"car": "", "car": "",
"default": ["", "", ""] "default": ["", "", ""]
}, },
"on-click": "playerctl play-pause", "on-click": "playerctl play-pause",
}, },
"battery": { "battery": {
"states": { "states": {
"warning": 30, "warning": 30,
"critical": 15 "critical": 15
}, },
"format": "{capacity}% {icon}", "format": "{capacity}% {icon}",
"format-charging": "{capacity}% ", "format-charging": "{capacity}% ",
"format-plugged": "{capacity}% ", "format-plugged": "{capacity}% ",
"format-alt": "{time} {icon}", "format-alt": "{time} {icon}",
// "format-good": "", // An empty format will hide the module // "format-good": "", // An empty format will hide the module
// "format-full": "", // "format-full": "",
"format-icons": ["", "", "", "", ""], "format-icons": ["", "", "", "", ""],
},
"clock": {
"timezone": "Europe/Brussels",
"format": "<big>{:%H:%M %d/%m/%Y}</big>", //"<big>{:%H:%M}</big>\n21-03-2022", //\n{:%d/%m/%Y}",
"format-alt": "{:%H:%M}",
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>",
}, },
"tray": { "tray": {
// "icon-size": 21, // "icon-size": 21,
"spacing": 10, "spacing": 10,
}, },
}, },
{ {
"position": "top", "position": "top",
"height": 20, "height": 20,
"modules-left": ["sway/mode"], "modules-left": ["sway/mode"],
"modules-center": ["sway/window"] "modules-center": ["sway/window"],
"modules-right": ["clock"],
"clock": {
"timezone": "Europe/Brussels",
"format": "{:%H:%M}",
"format-alt": "{:%H:%M %d/%m/%Y}", //"<big>{:%H:%M}</big>\n21-03-2022", //\n{:%d/%m/%Y}",
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>",
},
}] }]