Fixed broken notifications

This commit is contained in:
edwark43 2025-03-17 20:09:32 -04:00
parent 69da425885
commit dd6bae7680
4 changed files with 8 additions and 8 deletions

View File

@ -87,7 +87,7 @@ super + {_,shift + }q
# Reload Keybindings # Reload Keybindings
super + Escape super + Escape
pkill -USR1 -x sxhkd; dunstify -u low -i ~/.local/share/assets/reload.svg 'sxhkd' 'The configuration file has been reloaded successfully!' pkill -USR1 -x sxhkd; notify-send -u low -i ~/.local/share/assets/reload.svg 'sxhkd' 'The configuration file has been reloaded successfully!'
##### #####

View File

@ -7,7 +7,7 @@ function send_notification {
icon="$HOME/.local/share/assets/brightness.svg" icon="$HOME/.local/share/assets/brightness.svg"
brightness=$(brightnessctl i | grep -oP '\(\K[^%\)]+') brightness=$(brightnessctl i | grep -oP '\(\K[^%\)]+')
bar=$(seq -s "─" 0 $((brightness / 5)) | sed 's/[0-9]//g') bar=$(seq -s "─" 0 $((brightness / 5)) | sed 's/[0-9]//g')
dunstify "Brightness $brightness%" -i $icon -r 5555 -u normal -h int:value:$(($brightness)) notify-send "Brightness $brightness%" -i $icon -r 5555 -u normal -h int:value:$(($brightness))
} }
case $1 in case $1 in

View File

@ -9,9 +9,9 @@ filename="$dir/ss-${timestamp}.png"
show_notification() { show_notification() {
if [[ -e "$filename" ]]; then if [[ -e "$filename" ]]; then
dunstify --replace=699 -i "$filename" "Screenshot" "Screenshot saved and copied to clipboard" notify-send -r 699 -i "$filename" "Screenshot" "Screenshot saved and copied to clipboard"
else else
dunstify --replace=699 -i custom-trash-bin "Screenshot" "Screenshot Canceled" notify-send -r 699 -i user-trash "Screenshot" "Screenshot Canceled"
fi fi
} }
@ -23,7 +23,7 @@ take_screenshot() {
countdown() { countdown() {
for sec in $(seq "$1" -1 1); do for sec in $(seq "$1" -1 1); do
dunstify -t 1000 --replace=699 -i ~/.local/misc/share/assets/screenshot.svg "Taking screenshot in : $sec" notify-send -t 1000 -r 699 -i ~/.local/misc/share/assets/screenshot.svg "Taking screenshot in : $sec"
sleep 1 sleep 1
done done
} }

View File

@ -3,7 +3,7 @@
# Icons # Icons
vol_dir="$HOME/.local/share/assets" vol_dir="$HOME/.local/share/assets"
notify_cmd='dunstify -u low -h string:x-dunst-stack-tag:cvolum' notify_cmd='notify-send -u low -h string:x-dunst-stack-tag:cvolum'
# Get Volume # Get Volume
get_volume() { get_volume() {