one round of waybar styling later
This commit is contained in:
@@ -2,8 +2,7 @@
|
||||
exec-once = systemctl --user start /nix/store/*-hyprpolkitagent-*/libexec/hyprpolkitagent
|
||||
|
||||
# Wallpaper
|
||||
exec-once = swww-daemon &
|
||||
exec-once = sleep 2 && bash ~/dotfiles/scripts/load-wallpaper.sh
|
||||
exec-once = hyprpaper
|
||||
|
||||
# Notification Manager
|
||||
exec-once = dunst &
|
||||
@@ -12,13 +11,13 @@ exec-once = dunst &
|
||||
exec-once = wl-paste --watch cliphist store
|
||||
|
||||
# XDG Desktop Portal
|
||||
exec-once = bash ~/dotfiles/scripts/xdg.sh
|
||||
exec-once = bash ~/config/config/scripts/xdg.sh
|
||||
|
||||
# Set GTK Settings
|
||||
exec-once = bash ~/dotfiles/scripts/gtk.sh
|
||||
exec-once = bash ~/config/config/scripts/gtk.sh
|
||||
|
||||
# Start Hot Reload
|
||||
exec-once = bash ~/dotfiles/scripts/hot-reload.sh
|
||||
exec-once = bash ~/config/config/scripts/hot-reload.sh
|
||||
|
||||
# Start arRPC
|
||||
exec-once = arrpc
|
||||
|
||||
@@ -86,12 +86,12 @@ layerrule = animation slide right, notifications
|
||||
layerrule = dimaround, wofi
|
||||
|
||||
# Window Rules
|
||||
windowrule=float, blueman-manager
|
||||
windowrule=size 900 500, blueman-manager
|
||||
windowrule=center, blueman-manager
|
||||
windowrule=float, pavucontrol
|
||||
windowrule=size 900 500, pavucontrol
|
||||
windowrule=center, pavucontrol
|
||||
windowrule=float, .blueman-manager-wrapped
|
||||
windowrule=size 900 500, .blueman-manager-wrapped
|
||||
windowrule=center, .blueman-manager-wrapped
|
||||
windowrule=float, org.pulseaudio.pavucontrol
|
||||
windowrule=size 900 500, org.pulseaudio.pavucontrol
|
||||
windowrule=center, org.pulseaudio.pavucontrol
|
||||
windowrule=float, nm-connection-editor
|
||||
windowrule=size 900 500, nm-connection-editor
|
||||
windowrule=center, nm-connection-editor
|
||||
|
||||
@@ -3,10 +3,10 @@ bind = $mainMod, Z, togglespecialworkspace, quick
|
||||
bind = $mainMod SHIFT, Z, movetoworkspace, special:quick
|
||||
|
||||
# Hot reload
|
||||
bind = $mainMod SHIFT, B, exec, bash ~/dotfiles/scripts/hot-reload.sh
|
||||
bind = $mainMod SHIFT, B, exec, bash ~/config/scripts/hot-reload.sh
|
||||
|
||||
# Wallpaper
|
||||
bind = $mainMod SHIFT, RETURN, exec, bash ~/dotfiles/scripts/select-wallpaper.sh
|
||||
# bind = $mainMod SHIFT, RETURN, exec, bash ~/config/scripts/select-wallpaper.sh
|
||||
|
||||
# Screenshot keybinds
|
||||
bind = $mainMod, PRINT, exec, bash ~/dotfiles/scripts/screenshot-selection.sh
|
||||
|
||||
21
config/waybar/config
Normal file
21
config/waybar/config
Normal file
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"layer": "top",
|
||||
"margin-top": 6,
|
||||
"margin-bottom": -12,
|
||||
"margin-left": 8,
|
||||
"margin-right": 8,
|
||||
"spacing": 10,
|
||||
"include": [
|
||||
"~/config/config/waybar/modules.json"
|
||||
],
|
||||
"modules-left": [
|
||||
"hyprland/workspaces",
|
||||
"hyprland/window"
|
||||
],
|
||||
"modules-right": [
|
||||
"custom/regretevator_state",
|
||||
"custom/music",
|
||||
"group/traygroup",
|
||||
"clock"
|
||||
]
|
||||
}
|
||||
107
config/waybar/modules.json
Normal file
107
config/waybar/modules.json
Normal file
@@ -0,0 +1,107 @@
|
||||
{
|
||||
"group/traygroup": {
|
||||
"orientation": "inherit",
|
||||
"modules": ["tray", "network", "bluetooth", "pulseaudio"]
|
||||
},
|
||||
|
||||
"custom/middle-split": {
|
||||
"format": " "
|
||||
},
|
||||
|
||||
"custom/music": {
|
||||
"return-type": "json",
|
||||
"exec": "bash ~/config/scripts/waybar-music-status.sh",
|
||||
"restart-interval": 1,
|
||||
"on-scroll-up": "playerctl -p cider,OCbwoy3_s_iPhone volume 0.05+",
|
||||
"on-scroll-down": "playerctl -p cider,OCbwoy3_s_iPhone volume 0.05-",
|
||||
"on-click": "playerctl -p cider,OCbwoy3_s_iPhone play-pause",
|
||||
"on-click-right": "playerctl -p cider,OCbwoy3_s_iPhone next",
|
||||
"on-click-middle": "playerctl -p cider,OCbwoy3_s_iPhone previous",
|
||||
"smooth-scrolling-treshold": 40,
|
||||
"max-length": 60
|
||||
},
|
||||
|
||||
"custom/regretevator_state": {
|
||||
"restart-interval": 1,
|
||||
"return-type": "json",
|
||||
"exec": "cat /tmp/.regretevator_state"
|
||||
},
|
||||
|
||||
"hyprland/window": {
|
||||
"rewrite": {
|
||||
"Code - OSS": "Visual Studio Code",
|
||||
"Cider": "Apple Music",
|
||||
"SCPSL": "SCP: Secret Laboratory",
|
||||
"Sober": "Roblox",
|
||||
"roblox_wrapped - (.*)": "$1",
|
||||
"Minecraft: Forge Loading...": "Minecraft",
|
||||
"gemini.google.com_/app": "Gemini",
|
||||
"PORTAL 2 - (OpenGL|Vulkan)": "Portal 2",
|
||||
"HALF-LIFE 2 - (OpenGL|Vulkan)": "Half-Life 2",
|
||||
"(.*) - (.*) - Visual Studio Code": " $1 $2",
|
||||
"(.*) (— Mozilla Firefox( Private Browsing)?|— Brave)": "$1"
|
||||
},
|
||||
"separate-outputs": true
|
||||
},
|
||||
|
||||
"hyprland/workspaces": {
|
||||
"on-click": "activate",
|
||||
"active-only": false,
|
||||
"all-outputs": true,
|
||||
"show-special": false,
|
||||
"format": "{}",
|
||||
"format-icons": {
|
||||
"urgent": "",
|
||||
"active": "",
|
||||
"default": ""
|
||||
},
|
||||
"persistent-workspaces": {
|
||||
"*": 1
|
||||
}
|
||||
},
|
||||
|
||||
"tray": {
|
||||
"icon-size": 21,
|
||||
"spacing": 10
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"format": "{:%H:%M}",
|
||||
"tooltip-format": "{:%A %d %B %Y}",
|
||||
"format-alt": "{:%Y-%m-%d}"
|
||||
},
|
||||
|
||||
"pulseaudio": {
|
||||
"format": "{icon} {volume}%",
|
||||
"format-muted": " 0%",
|
||||
"format-source": " {volume}%",
|
||||
"format-source-muted": "",
|
||||
"format-icons": {
|
||||
"default": ["", "", ""]
|
||||
},
|
||||
"tooltip-format": "{desc}\n{icon} {volume}%",
|
||||
"on-click": "GTK_THEME=catppuccin-mocha-blue-standard+default pavucontrol"
|
||||
},
|
||||
|
||||
"network": {
|
||||
"format": "",
|
||||
"format-wifi": "",
|
||||
"format-ethernet": "",
|
||||
"format-disconnected": "",
|
||||
"tooltip-format": " {ifname} via {gwaddri}",
|
||||
"tooltip-format-wifi": " {ifname} @ {essid}\nIP: {ipaddr}\nStrength: {signalStrength}%\nFreq: {frequency}MHz\nUp: {bandwidthUpBits} Down: {bandwidthDownBits}",
|
||||
"tooltip-format-ethernet": " {ifname}\nIP: {ipaddr}\nUp: {bandwidthUpBits} Down: {bandwidthDownBits}",
|
||||
"tooltip-format-disconnected": "",
|
||||
"max-length": 50,
|
||||
"on-click": "GTK_THEME=catppuccin-mocha-blue-standard+default nm-connection-editor"
|
||||
},
|
||||
|
||||
"bluetooth": {
|
||||
"format": "",
|
||||
"format-disabled": "",
|
||||
"format-off": "",
|
||||
"interval": 1,
|
||||
"on-click": "GTK_THEME=catppuccin-mocha-blue-standard+default blueman-manager",
|
||||
"format-no-controller": ""
|
||||
}
|
||||
}
|
||||
127
config/waybar/style.css
Normal file
127
config/waybar/style.css
Normal file
@@ -0,0 +1,127 @@
|
||||
/* Global */
|
||||
|
||||
* {
|
||||
font-family: 'Symbols Nerd Font', 'Geist Sans';
|
||||
border: none;
|
||||
font-size: 15px;
|
||||
min-height: 10px;
|
||||
/* max-height: 10px;*/
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
border-radius: 8px;
|
||||
padding: 3px 5px 3px 5px;
|
||||
}
|
||||
|
||||
#workspaces, #custom-music, #traygroup, #clock, #window, #custom-regretevator_state {
|
||||
border-radius: 8px;
|
||||
padding: 2px 5px 2px 5px;
|
||||
border: 2px solid #89b4fa;
|
||||
}
|
||||
|
||||
#traygroup, #custom-music, #window, #workspaces, #custom-regretevator_state {
|
||||
background-color: #1e1e2e;
|
||||
padding-left: 5px;
|
||||
padding-right: 5px;
|
||||
color: #b4befe;
|
||||
}
|
||||
|
||||
#custom-regretevator_state {
|
||||
font-family: 'DotfilesFont', 'Symbols Nerd Font', 'Geist Sans';
|
||||
}
|
||||
|
||||
#custom-music, #clock, #window {
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
}
|
||||
|
||||
#clock {
|
||||
background-color: #1e1e2e;
|
||||
color: #b4befe;
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
color: #b4befe;
|
||||
}
|
||||
|
||||
#workspaces button.active {
|
||||
color: #cba6f7;
|
||||
font-weight: bolder;
|
||||
}
|
||||
|
||||
#tray {
|
||||
padding: 0px 5px 0px 5px;
|
||||
margin: 0px 0px 0px 0px;
|
||||
color: #b4befe;
|
||||
background-color: #1e1e2e;
|
||||
}
|
||||
|
||||
#tray menu {
|
||||
padding: 5px 5px 5px 5px;
|
||||
margin: 5px 5px 5px 5px;
|
||||
color: #b4befe;
|
||||
background-color: rgba(30, 30, 46, 0.9);
|
||||
border: 1px solid #89b4fa;
|
||||
border-radius: 13px;
|
||||
}
|
||||
|
||||
#tray menuitem {
|
||||
padding: 2px 2px 2px 2px;
|
||||
margin: 2px 0px 2px 0px;
|
||||
border-radius: 8px;
|
||||
color: #b4befe;
|
||||
background-color: rgba(30, 30, 46, 0);
|
||||
border: 1px solid #89b4fa;
|
||||
}
|
||||
|
||||
#tray menuitem:hover {
|
||||
color: #89b4fa;
|
||||
background-color: rgba(17, 17, 27, 0.8);
|
||||
}
|
||||
|
||||
#tray separatormenuitem {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#network, #bluetooth, #pulseaudio {
|
||||
padding: 0px 5px 0px 5px;
|
||||
margin: 0px 0px 0px 0px;
|
||||
}
|
||||
|
||||
#tray > .passive {
|
||||
-gtk-icon-effect: dim;
|
||||
}
|
||||
|
||||
#tray > .needs-attention {
|
||||
-gtk-icon-effect: highlight;
|
||||
}
|
||||
|
||||
.invisible {
|
||||
padding: 0px 0px 0px 0px;
|
||||
margin: 0px 0px 0px 0px;
|
||||
background-color: transparent;
|
||||
border: 2px transparent;
|
||||
}
|
||||
|
||||
tooltip {
|
||||
padding: 5px 5px 5px 5px;
|
||||
margin: 5px 5px 5px 5px;
|
||||
border-radius: 4px;
|
||||
background-color: rgba(30, 30, 46, 0.8);
|
||||
border: 1px solid #89b4fa;
|
||||
color: #cdd6f4;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
window#waybar.empty #window {
|
||||
padding: 0px 0px 0px 0px;
|
||||
margin: 0px 0px 0px 0px;
|
||||
border: 2px transparent;
|
||||
background-color: transparent;
|
||||
}
|
||||
@@ -76,6 +76,7 @@
|
||||
deno
|
||||
wofi
|
||||
waybar
|
||||
hyprpaper
|
||||
dunst
|
||||
hyprlock
|
||||
swww
|
||||
|
||||
14
scripts/hot-reload.sh
Normal file
14
scripts/hot-reload.sh
Normal file
@@ -0,0 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
pkill -9 waybar
|
||||
|
||||
hyprctl dispatch exec "GTK_THEME=Adwaita waybar -c ~/config/config/waybar/config -s ~/config/config/waybar/style.css" &
|
||||
hyprctl reload
|
||||
|
||||
ROBLOX_PID="$(pidof sober)"
|
||||
|
||||
echo ${#ROBLOX_PID}
|
||||
|
||||
if [ ${#ROBLOX_PID} -lt 1 ]; then
|
||||
rm /tmp/.regretevator_state
|
||||
fi
|
||||
16
scripts/waybar-music-status.sh
Normal file
16
scripts/waybar-music-status.sh
Normal file
@@ -0,0 +1,16 @@
|
||||
#!/bin/bash
|
||||
|
||||
function _sanitize {
|
||||
sed -r "s/(^[ ]*)|([ ]*$)//g" | sed -r 's/\&/\&/g' | sed -r 's/\"/\"/g' | sed -r "s/'/\'/g"
|
||||
}
|
||||
|
||||
# {{artist}} — {{title}}
|
||||
|
||||
SONGNAME="$( playerctl -s -p cider,OCbwoy3_s_iPhone metadata -f "{{artist}} — {{title}}" | _sanitize )"
|
||||
ALBUMNAME="$( playerctl -s -p cider,OCbwoy3_s_iPhone metadata album | _sanitize )"
|
||||
|
||||
if [ ${#SONGNAME} -gt 0 ] ; then
|
||||
printf "{\"text\": \" $SONGNAME\", \"tooltip\": \"$ALBUMNAME\", \"class\":\"music\" }"
|
||||
else
|
||||
printf "{\"text\": \"\", \"tooltip\": \" \", \"class\":\"invisible\" }"
|
||||
fi
|
||||
21
scripts/xdg.sh
Normal file
21
scripts/xdg.sh
Normal file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
|
||||
sleep 1
|
||||
|
||||
# kill all possible running xdg-desktop-portals
|
||||
kill -9 $(pidof xdg-desktop-portal-hyprland)
|
||||
kill -9 $(pidof xdg-desktop-portal-gnome)
|
||||
kill -9 $(pidof xdg-desktop-portal-kde)
|
||||
kill -9 $(pidof xdg-desktop-portal-lxqt)
|
||||
kill -9 $(pidof xdg-desktop-portal-wlr)
|
||||
kill -9 $(pidof xdg-desktop-portal-gtk)
|
||||
kill -9 $(pidof xdg-desktop-portal)
|
||||
sleep 1
|
||||
|
||||
# start xdg-desktop-portal-hyprland
|
||||
/usr/lib/xdg-desktop-portal-hyprland &
|
||||
sleep 2
|
||||
|
||||
# start xdg-desktop-portal
|
||||
/usr/lib/xdg-desktop-portal &
|
||||
sleep 1
|
||||
Reference in New Issue
Block a user