update config file
63
dotfiles/config/waybar/config-bottom.jsonc
Normal file
@@ -0,0 +1,63 @@
|
||||
{
|
||||
"layer": "top",
|
||||
"position": "bottom",
|
||||
"mod": "dock",
|
||||
"exclusive": true,
|
||||
"passthrough": false,
|
||||
"gtk-layer-shell": true,
|
||||
"height": 25,
|
||||
"modules-left": [
|
||||
"custom/launch_wofi",
|
||||
"custom/launch_firefox",
|
||||
"custom/launch_thunderbird",
|
||||
"custom/launch_kitty",
|
||||
"custom/launch_dolphin"
|
||||
],
|
||||
"modules-center": ["wlr/taskbar"],
|
||||
"modules-right": ["custom/weather"],
|
||||
|
||||
"custom/launch_firefox": {
|
||||
"format": "",
|
||||
"on-click": "google-chrome-stable",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/launch_thunderbird": {
|
||||
"format": "",
|
||||
"on-click": "thunderbird",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/launch_dolphin": {
|
||||
"format": "",
|
||||
"on-click": "exec dolphin",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/launch_kitty": {
|
||||
"format": "",
|
||||
"on-click": "exec kitty",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/launch_wofi": {
|
||||
"format": "",
|
||||
"on-click": "sh -c '(sleep 0.5s; pkill wofi || wofi -c ~/.config/wofi/config-lmenu)' & disown",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"wlr/taskbar": {
|
||||
"format": "{icon}",
|
||||
"icon-size": 24,
|
||||
"all-outputs": true,
|
||||
"tooltip-format": "{name} - {title}",
|
||||
"on-click": "activate",
|
||||
"on-click-middle": "close",
|
||||
"ignore-list": [
|
||||
"wofi"
|
||||
],
|
||||
"app_ids-mapping": {
|
||||
"steam_app_39210": "Final Fantasy 14"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -6,45 +6,70 @@
|
||||
"passthrough": false,
|
||||
"gtk-layer-shell": true,
|
||||
"height": 50,
|
||||
"modules-left": ["custom/launch_wofi","wlr/workspaces","cpu","memory","disk","hyprland/window"],
|
||||
"modules-center": ["custom/lock_screen","custom/updates","clock","custom/power_btn"],
|
||||
"modules-right": ["temperature","custom/power_profile","battery","backlight","pulseaudio","pulseaudio#microphone","tray","custom/weather","custom/light_dark"],
|
||||
|
||||
"modules-left": [
|
||||
"custom/launch_wofi",
|
||||
"wlr/workspaces",
|
||||
|
||||
"hyprland/window"
|
||||
],
|
||||
"modules-center": [
|
||||
"idle_inhibitor",
|
||||
"custom/lock_screen",
|
||||
"custom/power_btn",
|
||||
"custom/updates",
|
||||
"clock",
|
||||
"wlr/taskbar"
|
||||
],
|
||||
"modules-right": [
|
||||
"custom/weather",
|
||||
"cpu",
|
||||
"memory",
|
||||
"disk",
|
||||
"temperature",
|
||||
"battery",
|
||||
"backlight",
|
||||
"pulseaudio",
|
||||
"pulseaudio#microphone",
|
||||
"tray",
|
||||
"custom/light_dark"
|
||||
],
|
||||
"idle_inhibitor": {
|
||||
"format": "{icon}",
|
||||
"format-icons": {
|
||||
"activated": "",
|
||||
"deactivated": ""
|
||||
},
|
||||
"tooltip": true
|
||||
},
|
||||
"hyprland/window": {
|
||||
"format": "{}"
|
||||
},
|
||||
|
||||
"custom/launch_wofi": {
|
||||
"format": "",
|
||||
"on-click": "pkill wofi; wofi -n",
|
||||
"format": "",
|
||||
"on-click": "sh -c '(sleep 0.5s; pkill wofi || wofi -c ~/.config/wofi/config-lmenu)' & disown",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/lock_screen": {
|
||||
"format": "",
|
||||
"on-click": "sh -c '(sleep 0.5s; swaylock)' & disown",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/light_dark": {
|
||||
"format": "",
|
||||
"on-click": "~/.config/waybar/scripts/baraction light",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/power_btn": {
|
||||
"format": "",
|
||||
"on-click": "sh -c '(sleep 0.5s; wlogout --protocol layer-shell)' & disown",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"cpu": {
|
||||
"interval": 10,
|
||||
"format": " {usage}%",
|
||||
"max-length": 10,
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
},
|
||||
|
||||
"disk": {
|
||||
"interval": 30,
|
||||
"format": " {percentage_used}%",
|
||||
@@ -53,7 +78,6 @@
|
||||
"tooltip-format": "HDD - {used} used out of {total} on {path} ({percentage_used}%)",
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
},
|
||||
|
||||
"memory": {
|
||||
"interval": 30,
|
||||
"format": " {}%",
|
||||
@@ -62,7 +86,6 @@
|
||||
"tooltip-format": "Memory - {used:0.1f}GB used",
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
},
|
||||
|
||||
"custom/updates": {
|
||||
"format": "{}",
|
||||
"exec": "~/.config/waybar/scripts/update-sys",
|
||||
@@ -70,7 +93,6 @@
|
||||
"interval": 300,
|
||||
"tooltip": true
|
||||
},
|
||||
|
||||
"wlr/workspaces": {
|
||||
"disable-scroll": true,
|
||||
"all-outputs": true,
|
||||
@@ -88,65 +110,17 @@
|
||||
"10": []
|
||||
}
|
||||
},
|
||||
|
||||
"custom/power_profile": {
|
||||
//shows the current power profile and switches to next on click
|
||||
"exec": "asusctl profile -p | sed s:'Active profile is'::",
|
||||
"interval": 30,
|
||||
"format": "{}",
|
||||
"on-click": "asusctl profile -n; pkill -SIGRTMIN+8 waybar",
|
||||
"signal": 8
|
||||
},
|
||||
|
||||
"custom/weather": {
|
||||
//shows the current weather and forecast
|
||||
"tooltip" : true,
|
||||
"format" : "{}",
|
||||
"interval" : 30,
|
||||
"exec" : "~/.config/waybar/scripts/waybar-wttr.py",
|
||||
"return-type" : "json"
|
||||
},
|
||||
|
||||
"tray": {
|
||||
"icon-size": 18,
|
||||
"spacing": 10
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"format": "{:%I:%M %p}",
|
||||
"tooltip": true,
|
||||
"tooltip-format": "{: %A, %B %e %Y}"
|
||||
},
|
||||
|
||||
"backlight": {
|
||||
"device": "intel_backlight",
|
||||
"format": "{icon} {percent}%",
|
||||
"format-icons": ["", "", ""],
|
||||
"on-scroll-up": "brightnessctl set 1%+",
|
||||
"on-scroll-down": "brightnessctl set 1%-",
|
||||
"min-length": 6
|
||||
},
|
||||
|
||||
"battery": {
|
||||
"states": {
|
||||
"good": 95,
|
||||
"warning": 30,
|
||||
"critical": 20
|
||||
},
|
||||
"format": "{icon} {capacity}%",
|
||||
"format-charging": " {capacity}%",
|
||||
"format-plugged": " {capacity}%",
|
||||
"format-alt": "{time} {icon}",
|
||||
"format-icons": ["", "", "", "", "", "", "", "", "", "", ""]
|
||||
},
|
||||
|
||||
"pulseaudio": {
|
||||
"format": "{icon} {volume}%",
|
||||
"format": "{icon}",
|
||||
"format-muted": "",
|
||||
"on-click": "pamixer -t",
|
||||
"on-click": "~/.config/waybar/scripts/volume --toggle",
|
||||
"on-click-right": "pavucontrol",
|
||||
"on-scroll-up": "pamixer -i 5",
|
||||
"on-scroll-down": "pamixer -d 5",
|
||||
"on-scroll-up": "~/.config/waybar/scripts/volume --inc",
|
||||
"on-scroll-down": "~/.config/waybar/scripts/volume --dec",
|
||||
"scroll-step": 5,
|
||||
"format-icons": {
|
||||
"headphone": "",
|
||||
@@ -156,25 +130,58 @@
|
||||
"portable": "",
|
||||
"car": "",
|
||||
"default": ["", "", ""]
|
||||
}
|
||||
},
|
||||
"tooltip": true,
|
||||
"tooltip-format": "{icon} at {volume}%"
|
||||
},
|
||||
|
||||
"pulseaudio#microphone": {
|
||||
"format": "{format_source}",
|
||||
"format-source": " {volume}%",
|
||||
"format-source-muted": "",
|
||||
"on-click": "pamixer --default-source -t",
|
||||
"format-source": "",
|
||||
"format-source-muted": "",
|
||||
"on-click": "~/.config/waybar/scripts/volume --toggle-mic",
|
||||
"on-click-right": "pavucontrol",
|
||||
"on-scroll-up": "pamixer --default-source -i 5",
|
||||
"on-scroll-down": "pamixer --default-source -d 5",
|
||||
"scroll-step": 5
|
||||
"on-scroll-up": "~/.config/waybar/scripts/volume --mic-inc",
|
||||
"on-scroll-down": "~/.config/waybar/scripts/volume --mic-dec",
|
||||
"scroll-step": 5,
|
||||
"tooltip": true,
|
||||
"tooltip-format": " at {volume}%"
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"format": "{:%H:%M}",
|
||||
"tooltip-format": "{: %A, %e %B %Y}"
|
||||
},
|
||||
|
||||
"custom/weather": {
|
||||
//shows the current weather and forecast
|
||||
"tooltip" : true,
|
||||
"format" : "{}",
|
||||
"interval" : 30,
|
||||
"exec" : "~/.config/waybar/scripts/waybar-wttr.py",
|
||||
"return-type" : "json"
|
||||
},
|
||||
|
||||
"temperature": {
|
||||
"thermal-zone": 1,
|
||||
"format": " {temperatureC}°C",
|
||||
"format": "",
|
||||
"format-alt-click": "click-right",
|
||||
"format-alt": " {temperatureC}°C",
|
||||
"critical-threshold": 70,
|
||||
"format-critical": " {temperatureF}°F",
|
||||
"format-critical": " {temperatureC}°C",
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
},
|
||||
|
||||
"wlr/taskbar": {
|
||||
"format": "{icon}",
|
||||
"icon-size": 24,
|
||||
"all-outputs": true,
|
||||
"tooltip-format": "{name} - {title}",
|
||||
"on-click": "activate",
|
||||
"on-click-middle": "close",
|
||||
"ignore-list": [
|
||||
"wofi"
|
||||
],
|
||||
"app_ids-mapping": {
|
||||
"steam_app_39210": "Final Fantasy 14"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,180 +0,0 @@
|
||||
{
|
||||
"layer": "top",
|
||||
"position": "top",
|
||||
"mod": "dock",
|
||||
"exclusive": true,
|
||||
"passthrough": false,
|
||||
"gtk-layer-shell": true,
|
||||
"height": 50,
|
||||
"modules-left": ["custom/launch_wofi","wlr/workspaces","cpu","memory","disk","hyprland/window"],
|
||||
"modules-center": ["custom/lock_screen","custom/updates","clock","custom/power_btn"],
|
||||
"modules-right": ["temperature","custom/power_profile","battery","backlight","pulseaudio","pulseaudio#microphone","tray","custom/weather","custom/light_dark"],
|
||||
|
||||
"hyprland/window": {
|
||||
"format": "{}"
|
||||
},
|
||||
|
||||
"custom/launch_wofi": {
|
||||
"format": "",
|
||||
"on-click": "pkill wofi; wofi -n",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/lock_screen": {
|
||||
"format": "",
|
||||
"on-click": "sh -c '(sleep 0.5s; swaylock)' & disown",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/light_dark": {
|
||||
"format": "",
|
||||
"on-click": "~/.config/waybar/scripts/baraction light",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/power_btn": {
|
||||
"format": "",
|
||||
"on-click": "sh -c '(sleep 0.5s; wlogout --protocol layer-shell)' & disown",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"cpu": {
|
||||
"interval": 10,
|
||||
"format": " {usage}%",
|
||||
"max-length": 10,
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
},
|
||||
|
||||
"disk": {
|
||||
"interval": 30,
|
||||
"format": " {percentage_used}%",
|
||||
"path": "/",
|
||||
"tooltip": true,
|
||||
"tooltip-format": "HDD - {used} used out of {total} on {path} ({percentage_used}%)",
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
},
|
||||
|
||||
"memory": {
|
||||
"interval": 30,
|
||||
"format": " {}%",
|
||||
"max-length": 10,
|
||||
"tooltip": true,
|
||||
"tooltip-format": "Memory - {used:0.1f}GB used",
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
},
|
||||
|
||||
"custom/updates": {
|
||||
"format": "{}",
|
||||
"exec": "~/.config/waybar/scripts/update-sys",
|
||||
"on-click": "~/.config/waybar/scripts/update-sys update",
|
||||
"interval": 300,
|
||||
"tooltip": true
|
||||
},
|
||||
|
||||
"wlr/workspaces": {
|
||||
"disable-scroll": true,
|
||||
"all-outputs": true,
|
||||
"on-click": "activate",
|
||||
"persistent_workspaces": {
|
||||
"1": [],
|
||||
"2": [],
|
||||
"3": [],
|
||||
"4": [],
|
||||
"5": [],
|
||||
"6": [],
|
||||
"7": [],
|
||||
"8": [],
|
||||
"9": [],
|
||||
"10": []
|
||||
}
|
||||
},
|
||||
|
||||
"custom/power_profile": {
|
||||
//shows the current power profile and switches to next on click
|
||||
"exec": "asusctl profile -p | sed s:'Active profile is'::",
|
||||
"interval": 30,
|
||||
"format": "{}",
|
||||
"on-click": "asusctl profile -n; pkill -SIGRTMIN+8 waybar",
|
||||
"signal": 8
|
||||
},
|
||||
|
||||
"custom/weather": {
|
||||
//shows the current weather and forecast
|
||||
"tooltip" : true,
|
||||
"format" : "{}",
|
||||
"interval" : 30,
|
||||
"exec" : "~/.config/waybar/scripts/waybar-wttr.py",
|
||||
"return-type" : "json"
|
||||
},
|
||||
|
||||
"tray": {
|
||||
"icon-size": 18,
|
||||
"spacing": 10
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"format": "{:%I:%M %p}",
|
||||
"tooltip": true,
|
||||
"tooltip-format": "{: %A, %B %e %Y}"
|
||||
},
|
||||
|
||||
"backlight": {
|
||||
"device": "intel_backlight",
|
||||
"format": "{icon} {percent}%",
|
||||
"format-icons": ["", "", ""],
|
||||
"on-scroll-up": "brightnessctl set 1%+",
|
||||
"on-scroll-down": "brightnessctl set 1%-",
|
||||
"min-length": 6
|
||||
},
|
||||
|
||||
"battery": {
|
||||
"states": {
|
||||
"good": 95,
|
||||
"warning": 30,
|
||||
"critical": 20
|
||||
},
|
||||
"format": "{icon} {capacity}%",
|
||||
"format-charging": " {capacity}%",
|
||||
"format-plugged": " {capacity}%",
|
||||
"format-alt": "{time} {icon}",
|
||||
"format-icons": ["", "", "", "", "", "", "", "", "", "", ""]
|
||||
},
|
||||
|
||||
"pulseaudio": {
|
||||
"format": "{icon} {volume}%",
|
||||
"format-muted": "",
|
||||
"on-click": "pamixer -t",
|
||||
"on-click-right": "pavucontrol",
|
||||
"on-scroll-up": "pamixer -i 5",
|
||||
"on-scroll-down": "pamixer -d 5",
|
||||
"scroll-step": 5,
|
||||
"format-icons": {
|
||||
"headphone": "",
|
||||
"hands-free": "",
|
||||
"headset": "",
|
||||
"phone": "",
|
||||
"portable": "",
|
||||
"car": "",
|
||||
"default": ["", "", ""]
|
||||
}
|
||||
},
|
||||
|
||||
"pulseaudio#microphone": {
|
||||
"format": "{format_source}",
|
||||
"format-source": " {volume}%",
|
||||
"format-source-muted": "",
|
||||
"on-click": "pamixer --default-source -t",
|
||||
"on-click-right": "pavucontrol",
|
||||
"on-scroll-up": "pamixer --default-source -i 5",
|
||||
"on-scroll-down": "pamixer --default-source -d 5",
|
||||
"scroll-step": 5
|
||||
},
|
||||
|
||||
"temperature": {
|
||||
"thermal-zone": 1,
|
||||
"format": " {temperatureC}°C",
|
||||
"critical-threshold": 70,
|
||||
"format-critical": " {temperatureF}°F",
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
}
|
||||
}
|
||||
BIN
dotfiles/config/waybar/icons/brightness-100.png
Normal file
|
After Width: | Height: | Size: 32 KiB |
BIN
dotfiles/config/waybar/icons/brightness-20.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
dotfiles/config/waybar/icons/brightness-40.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
dotfiles/config/waybar/icons/brightness-60.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
dotfiles/config/waybar/icons/brightness-80.png
Normal file
|
After Width: | Height: | Size: 32 KiB |
BIN
dotfiles/config/waybar/icons/microphone-mute.png
Normal file
|
After Width: | Height: | Size: 27 KiB |
BIN
dotfiles/config/waybar/icons/microphone.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
dotfiles/config/waybar/icons/volume-high.png
Normal file
|
After Width: | Height: | Size: 27 KiB |
BIN
dotfiles/config/waybar/icons/volume-low.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
dotfiles/config/waybar/icons/volume-mid.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
dotfiles/config/waybar/icons/volume-mute.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
25
dotfiles/config/waybar/mesu-met.jsonc
Normal file
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"clock": {
|
||||
"format": "{:%H:%M}",
|
||||
"tooltip-format": "{: %A, %e %B %Y}"
|
||||
},
|
||||
|
||||
"custom/weather": {
|
||||
//shows the current weather and forecast
|
||||
"tooltip" : true,
|
||||
"format" : "{}",
|
||||
"interval" : 30,
|
||||
"exec" : "~/.config/HyprV/waybar/scripts/waybar-wttr-c.py",
|
||||
"return-type" : "json"
|
||||
},
|
||||
|
||||
"temperature": {
|
||||
"thermal-zone": 1,
|
||||
"format": "",
|
||||
"format-alt-click": "click-right",
|
||||
"format-alt": " {temperatureC}°C",
|
||||
"critical-threshold": 70,
|
||||
"format-critical": " {temperatureC}°C",
|
||||
"on-click": "kitty --start-as=fullscreen --title btop sh -c 'btop'"
|
||||
}
|
||||
}
|
||||
@@ -14,19 +14,27 @@ ln -sf ~/.config/waybar/style/style$SWITCHTO.css ~/.config/waybar/style.css
|
||||
#set the wofi theme
|
||||
ln -sf ~/.config/wofi/style/style$SWITCHTO.css ~/.config/wofi/style.css
|
||||
|
||||
#set the xfce theme
|
||||
xfconf-query -c xsettings -p /Net/ThemeName -s "Adwaita$SWITCHTO"
|
||||
xfconf-query -c xsettings -p /Net/IconThemeName -s "Adwaita$SWITCHTO"
|
||||
|
||||
#set the GTK theme
|
||||
gsettings set org.gnome.desktop.interface gtk-theme "Adwaita$SWITCHTO"
|
||||
gsettings set org.gnome.desktop.interface icon-theme "Adwaita$SWITCHTO"
|
||||
#set the xfce and GTK theme
|
||||
# if [ $VER == "v4" ]; then
|
||||
# xfconf-query -c xsettings -p /Net/IconThemeName -s "Papirus-Dark"
|
||||
# gsettings set org.gnome.desktop.interface icon-theme "Papirus-Dark"
|
||||
# else
|
||||
# xfconf-query -c xsettings -p /Net/IconThemeName -s "Adwaita$SWITCHTO"
|
||||
# gsettings set org.gnome.desktop.interface icon-theme "Adwaita$SWITCHTO"
|
||||
# fi
|
||||
|
||||
#change the background image and be cool about it ;)
|
||||
swww img ~/.config/hypr/wallpaper$SWITCHTO.jpg --transition-fps 60 --transition-type wipe --transition-duration 2
|
||||
|
||||
#update the sddm image
|
||||
ln -sf /usr/share/sddm/themes/sdt/Backgrounds/wallpaper$SWITCHTO.jpg /usr/share/sddm/themes/sdt/wallpaper.jpg
|
||||
#reset mako
|
||||
sleep 1
|
||||
killall -SIGUSR2 dunst
|
||||
dunst &
|
||||
|
||||
#restart the waybar
|
||||
killall -SIGUSR2 waybar
|
||||
#killall -SIGUSR2 waybar <-- start causing web brwsers to close so switched to below...
|
||||
pkill waybar
|
||||
waybar &
|
||||
|
||||
# bottom waybar
|
||||
#waybar --config ~/.config/waybar/config-bottom.jsonc
|
||||
|
||||
52
dotfiles/config/waybar/scripts/brightness
Executable file
@@ -0,0 +1,52 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
iDIR="$HOME/.config/waybar/icons"
|
||||
|
||||
# Get brightness
|
||||
get_backlight() {
|
||||
LIGHT=$(printf "%.0f\n" $(brightnessctl i))
|
||||
echo "${LIGHT}%"
|
||||
}
|
||||
|
||||
# Get icons
|
||||
get_icon() {
|
||||
backlight="$(brightnessctl g)"
|
||||
current="${backlight%%%}"
|
||||
if [[ ("$current" -ge "0") && ("$current" -le "52") ]]; then
|
||||
icon="$iDIR/brightness-20.png"
|
||||
elif [[ ("$current" -ge "52") && ("$current" -le "103") ]]; then
|
||||
icon="$iDIR/brightness-40.png"
|
||||
elif [[ ("$current" -ge "103") && ("$current" -le "155") ]]; then
|
||||
icon="$iDIR/brightness-60.png"
|
||||
elif [[ ("$current" -ge "155") && ("$current" -le "207") ]]; then
|
||||
icon="$iDIR/brightness-80.png"
|
||||
elif [[ ("$current" -ge "180") && ("$current" -le "255") ]]; then
|
||||
icon="$iDIR/brightness-100.png"
|
||||
fi
|
||||
}
|
||||
|
||||
# Notify
|
||||
notify_user() {
|
||||
notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$icon" "Brightness : $(brightnessctl g)"
|
||||
}
|
||||
|
||||
# Increase brightness
|
||||
inc_backlight() {
|
||||
brightnessctl set 10%+ && get_icon && notify_user
|
||||
}
|
||||
|
||||
# Decrease brightness
|
||||
dec_backlight() {
|
||||
brightnessctl set 10%- && get_icon && notify_user
|
||||
}
|
||||
|
||||
# Execute accordingly
|
||||
if [[ "$1" == "--get" ]]; then
|
||||
brightnessctl g
|
||||
elif [[ "$1" == "--inc" ]]; then
|
||||
inc_backlight
|
||||
elif [[ "$1" == "--dec" ]]; then
|
||||
dec_backlight
|
||||
else
|
||||
get_backlight
|
||||
fi
|
||||
106
dotfiles/config/waybar/scripts/volume
Executable file
@@ -0,0 +1,106 @@
|
||||
#!/bin/bash
|
||||
|
||||
iDIR="$HOME/.config/waybar/icons"
|
||||
|
||||
# Get Volume
|
||||
get_volume() {
|
||||
volume=$(pamixer --get-volume)
|
||||
echo "$volume"
|
||||
}
|
||||
|
||||
# Get icons
|
||||
get_icon() {
|
||||
current=$(get_volume)
|
||||
if [[ "$current" -eq "0" ]]; then
|
||||
echo "$iDIR/volume-mute.png"
|
||||
elif [[ ("$current" -ge "0") && ("$current" -le "30") ]]; then
|
||||
echo "$iDIR/volume-low.png"
|
||||
elif [[ ("$current" -ge "30") && ("$current" -le "60") ]]; then
|
||||
echo "$iDIR/volume-mid.png"
|
||||
elif [[ ("$current" -ge "60") && ("$current" -le "100") ]]; then
|
||||
echo "$iDIR/volume-high.png"
|
||||
fi
|
||||
}
|
||||
|
||||
# Notify
|
||||
notify_user() {
|
||||
notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$(get_icon)" "Volume : $(get_volume) %"
|
||||
}
|
||||
|
||||
# Increase Volume
|
||||
inc_volume() {
|
||||
pamixer -i 5 && notify_user
|
||||
}
|
||||
|
||||
# Decrease Volume
|
||||
dec_volume() {
|
||||
pamixer -d 5 && notify_user
|
||||
}
|
||||
|
||||
# Toggle Mute
|
||||
toggle_mute() {
|
||||
if [ "$(pamixer --get-mute)" == "false" ]; then
|
||||
pamixer -m && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$iDIR/volume-mute.png" "Volume Switched OFF"
|
||||
elif [ "$(pamixer --get-mute)" == "true" ]; then
|
||||
pamixer -u && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$(get_icon)" "Volume Switched ON"
|
||||
fi
|
||||
}
|
||||
|
||||
# Toggle Mic
|
||||
toggle_mic() {
|
||||
if [ "$(pamixer --default-source --get-mute)" == "false" ]; then
|
||||
pamixer --default-source -m && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$iDIR/microphone-mute.png" "Microphone Switched OFF"
|
||||
elif [ "$(pamixer --default-source --get-mute)" == "true" ]; then
|
||||
pamixer -u --default-source u && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$iDIR/microphone.png" "Microphone Switched ON"
|
||||
fi
|
||||
}
|
||||
# Get icons
|
||||
get_mic_icon() {
|
||||
current=$(pamixer --default-source --get-volume)
|
||||
if [[ "$current" -eq "0" ]]; then
|
||||
echo "$iDIR/microphone.png"
|
||||
elif [[ ("$current" -ge "0") && ("$current" -le "30") ]]; then
|
||||
echo "$iDIR/microphone.png"
|
||||
elif [[ ("$current" -ge "30") && ("$current" -le "60") ]]; then
|
||||
echo "$iDIR/microphone.png"
|
||||
elif [[ ("$current" -ge "60") && ("$current" -le "100") ]]; then
|
||||
echo "$iDIR/microphone.png"
|
||||
fi
|
||||
}
|
||||
# Notify
|
||||
notify_mic_user() {
|
||||
notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$(get_mic_icon)" "Mic-Level : $(pamixer --default-source --get-volume) %"
|
||||
}
|
||||
|
||||
# Increase MIC Volume
|
||||
inc_mic_volume() {
|
||||
pamixer --default-source -i 5 && notify_mic_user
|
||||
}
|
||||
|
||||
# Decrease MIC Volume
|
||||
dec_mic_volume() {
|
||||
pamixer --default-source -d 5 && notify_mic_user
|
||||
}
|
||||
|
||||
# Execute accordingly
|
||||
if [[ "$1" == "--get" ]]; then
|
||||
get_volume
|
||||
elif [[ "$1" == "--inc" ]]; then
|
||||
inc_volume
|
||||
elif [[ "$1" == "--dec" ]]; then
|
||||
dec_volume
|
||||
elif [[ "$1" == "--toggle" ]]; then
|
||||
toggle_mute
|
||||
elif [[ "$1" == "--toggle-mic" ]]; then
|
||||
toggle_mic
|
||||
elif [[ "$1" == "--get-icon" ]]; then
|
||||
get_icon
|
||||
elif [[ "$1" == "--get-mic-icon" ]]; then
|
||||
get_mic_icon
|
||||
elif [[ "$1" == "--mic-inc" ]]; then
|
||||
inc_mic_volume
|
||||
elif [[ "$1" == "--mic-dec" ]]; then
|
||||
dec_mic_volume
|
||||
else
|
||||
get_volume
|
||||
fi
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
window#waybar {
|
||||
background: rgba(21, 18, 27, 0);
|
||||
color: #cdd6f4;
|
||||
color: #f6f7fc;
|
||||
}
|
||||
|
||||
tooltip {
|
||||
@@ -27,22 +27,12 @@ tooltip label{
|
||||
|
||||
#workspaces button {
|
||||
padding: 5px;
|
||||
color: #313244;
|
||||
color: #f6f7fc;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
#workspaces button.active {
|
||||
color: #a6adc8;
|
||||
}
|
||||
|
||||
#workspaces button.focused {
|
||||
color: #a6adc8;
|
||||
background: #eba0ac;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
#workspaces button.urgent {
|
||||
color: #11111b;
|
||||
color: #000000;
|
||||
background: #a6e3a1;
|
||||
border-radius: 10px;
|
||||
}
|
||||
@@ -54,11 +44,16 @@ tooltip label{
|
||||
}
|
||||
|
||||
#custom-launch_wofi,
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_thunderbird,
|
||||
#custom-launch_thunar,
|
||||
#custom-launch_kitty,
|
||||
#custom-lock_screen,
|
||||
#custom-light_dark,
|
||||
#custom-power_btn,
|
||||
#custom-power_profile,
|
||||
#custom-weather,
|
||||
#custom-myhyprv,
|
||||
#window,
|
||||
#cpu,
|
||||
#disk,
|
||||
@@ -71,65 +66,43 @@ tooltip label{
|
||||
#tray,
|
||||
#temperature,
|
||||
#workspaces,
|
||||
#idle_inhibitor,
|
||||
#backlight {
|
||||
background: #1e1e2e;
|
||||
opacity: 0.8;
|
||||
padding: 0px 10px;
|
||||
margin: 3px 0px;
|
||||
margin-top: 10px;
|
||||
background: rgba(21, 18, 27, 0);
|
||||
opacity: 1;
|
||||
padding: 0px 8px;
|
||||
margin: 0px 3px;
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
#tray, #custom-lock_screen, #temperature, #backlight, #custom-launch_wofi, #cpu {
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
}
|
||||
|
||||
#custom-light_dark, #custom-power_btn, #workspaces, #pulseaudio.microphone, #battery, #disk {
|
||||
border-radius: 0px 10px 10px 0px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
#temperature.critical {
|
||||
color: #e92d4d;
|
||||
}
|
||||
|
||||
|
||||
#workspaces {
|
||||
padding-right: 0px;
|
||||
padding-left: 5px;
|
||||
}
|
||||
|
||||
#custom-power_profile {
|
||||
color: #a6e3a1;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#window {
|
||||
border-radius: 10px;
|
||||
margin-left: 20px;
|
||||
margin-left: 0px;
|
||||
margin-right: 0px;
|
||||
}
|
||||
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_thunderbird,
|
||||
#custom-launch_thunar,
|
||||
#custom-launch_wofi,
|
||||
#custom-launch_kitty,
|
||||
#custom-weather {
|
||||
margin-left: 0px;
|
||||
border-right: 0px;
|
||||
font-size: 24px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
|
||||
#custom-launch_wofi {
|
||||
color: #89b4fa;
|
||||
margin-left: 10px;
|
||||
border-right: 0px;
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_kitty {
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
#pulseaudio {
|
||||
color: #89b4fa;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#pulseaudio.microphone {
|
||||
color: #cba6f7;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#battery {
|
||||
color: #a6e3a1;
|
||||
border-left: 0px;
|
||||
}
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
window#waybar {
|
||||
background: rgba(21, 18, 27, 0);
|
||||
color: #cdd6f4;
|
||||
color: #f6f7fc;
|
||||
}
|
||||
|
||||
tooltip {
|
||||
@@ -27,22 +27,12 @@ tooltip label{
|
||||
|
||||
#workspaces button {
|
||||
padding: 5px;
|
||||
color: #313244;
|
||||
color: #f6f7fc;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
#workspaces button.active {
|
||||
color: #a6adc8;
|
||||
}
|
||||
|
||||
#workspaces button.focused {
|
||||
color: #a6adc8;
|
||||
background: #eba0ac;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
#workspaces button.urgent {
|
||||
color: #11111b;
|
||||
color: #000000;
|
||||
background: #a6e3a1;
|
||||
border-radius: 10px;
|
||||
}
|
||||
@@ -54,11 +44,16 @@ tooltip label{
|
||||
}
|
||||
|
||||
#custom-launch_wofi,
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_thunderbird,
|
||||
#custom-launch_thunar,
|
||||
#custom-launch_kitty,
|
||||
#custom-lock_screen,
|
||||
#custom-light_dark,
|
||||
#custom-power_btn,
|
||||
#custom-power_profile,
|
||||
#custom-weather,
|
||||
#custom-myhyprv,
|
||||
#window,
|
||||
#cpu,
|
||||
#disk,
|
||||
@@ -71,65 +66,43 @@ tooltip label{
|
||||
#tray,
|
||||
#temperature,
|
||||
#workspaces,
|
||||
#idle_inhibitor,
|
||||
#backlight {
|
||||
background: #1e1e2e;
|
||||
opacity: 0.8;
|
||||
padding: 0px 10px;
|
||||
margin: 3px 0px;
|
||||
margin-top: 10px;
|
||||
background: rgba(21, 18, 27, 0);
|
||||
opacity: 1;
|
||||
padding: 0px 8px;
|
||||
margin: 0px 3px;
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
#tray, #custom-lock_screen, #temperature, #backlight, #custom-launch_wofi, #cpu {
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
}
|
||||
|
||||
#custom-light_dark, #custom-power_btn, #workspaces, #pulseaudio.microphone, #battery, #disk {
|
||||
border-radius: 0px 10px 10px 0px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
#temperature.critical {
|
||||
color: #e92d4d;
|
||||
}
|
||||
|
||||
|
||||
#workspaces {
|
||||
padding-right: 0px;
|
||||
padding-left: 5px;
|
||||
}
|
||||
|
||||
#custom-power_profile {
|
||||
color: #a6e3a1;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#window {
|
||||
border-radius: 10px;
|
||||
margin-left: 20px;
|
||||
margin-left: 0px;
|
||||
margin-right: 0px;
|
||||
}
|
||||
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_thunderbird,
|
||||
#custom-launch_thunar,
|
||||
#custom-launch_wofi,
|
||||
#custom-launch_kitty,
|
||||
#custom-weather {
|
||||
margin-left: 0px;
|
||||
border-right: 0px;
|
||||
font-size: 24px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
|
||||
#custom-launch_wofi {
|
||||
color: #89b4fa;
|
||||
margin-left: 10px;
|
||||
border-right: 0px;
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_kitty {
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
#pulseaudio {
|
||||
color: #89b4fa;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#pulseaudio.microphone {
|
||||
color: #cba6f7;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#battery {
|
||||
color: #a6e3a1;
|
||||
border-left: 0px;
|
||||
}
|
||||
@@ -9,11 +9,11 @@
|
||||
|
||||
window#waybar {
|
||||
background: rgba(21, 18, 27, 0);
|
||||
color: #2b2b2c;
|
||||
color: #f6f7fc;
|
||||
}
|
||||
|
||||
tooltip {
|
||||
background: #e7e7ec;;
|
||||
background: #e7e7ec;
|
||||
opacity: 0.8;
|
||||
border-radius: 10px;
|
||||
border-width: 2px;
|
||||
@@ -27,22 +27,12 @@ tooltip label{
|
||||
|
||||
#workspaces button {
|
||||
padding: 5px;
|
||||
color: #313244;
|
||||
color: #f6f7fc;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
#workspaces button.active {
|
||||
color: #a6adc8;
|
||||
}
|
||||
|
||||
#workspaces button.focused {
|
||||
color: #a6adc8;
|
||||
background: #eba0ac;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
#workspaces button.urgent {
|
||||
color: #11111b;
|
||||
color: #000000;
|
||||
background: #a6e3a1;
|
||||
border-radius: 10px;
|
||||
}
|
||||
@@ -54,11 +44,16 @@ tooltip label{
|
||||
}
|
||||
|
||||
#custom-launch_wofi,
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_thunderbird,
|
||||
#custom-launch_thunar,
|
||||
#custom-launch_kitty,
|
||||
#custom-lock_screen,
|
||||
#custom-light_dark,
|
||||
#custom-power_btn,
|
||||
#custom-power_profile,
|
||||
#custom-weather,
|
||||
#custom-myhyprv,
|
||||
#window,
|
||||
#cpu,
|
||||
#disk,
|
||||
@@ -71,24 +66,15 @@ tooltip label{
|
||||
#tray,
|
||||
#temperature,
|
||||
#workspaces,
|
||||
#idle_inhibitor,
|
||||
#backlight {
|
||||
background: #e7e7ec;
|
||||
background: rgba(21, 18, 27, 0);
|
||||
opacity: 0.8;
|
||||
padding: 0px 10px;
|
||||
margin: 3px 0px;
|
||||
margin-top: 10px;
|
||||
padding: 0px 8px;
|
||||
margin: 0px 3px;
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
#tray, #custom-lock_screen, #temperature, #backlight, #custom-launch_wofi, #cpu {
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
}
|
||||
|
||||
#custom-light_dark, #custom-power_btn, #workspaces, #pulseaudio.microphone, #battery, #disk{
|
||||
border-radius: 0px 10px 10px 0px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
#temperature.critical {
|
||||
color: #e92d4d;
|
||||
}
|
||||
@@ -99,37 +85,25 @@ tooltip label{
|
||||
padding-left: 5px;
|
||||
}
|
||||
|
||||
#custom-power_profile {
|
||||
color: #1d7715;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#window {
|
||||
border-radius: 10px;
|
||||
margin-left: 20px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
|
||||
#custom-launch_wofi {
|
||||
color: #407cdd;
|
||||
margin-left: 10px;
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_thunderbird,
|
||||
#custom-launch_thunar,
|
||||
#custom-launch_wofi,
|
||||
#custom-launch_kitty,
|
||||
#custom-weather {
|
||||
margin-left: 0px;
|
||||
border-right: 0px;
|
||||
font-size: 24px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
|
||||
#pulseaudio {
|
||||
color: #407cdd;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#pulseaudio.microphone {
|
||||
color: #ad6bfd;
|
||||
border-left: 0px;
|
||||
border-right: 0px;
|
||||
}
|
||||
|
||||
#battery {
|
||||
color: #1d7715;
|
||||
border-left: 0px;
|
||||
}
|
||||
#custom-launch_firefox,
|
||||
#custom-launch_kitty {
|
||||
font-size: 20px;
|
||||
}
|
||||