From 1d749b2446e8bf3880841fd503ead6bf7409948e Mon Sep 17 00:00:00 2001 From: Daniel Heras Quesada Date: Mon, 11 May 2026 18:02:10 +0200 Subject: [PATCH] feat: audo notifications format improvements --- utils/notifications/audio.sh | 4 ++-- utils/notifications/mpd.sh | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/utils/notifications/audio.sh b/utils/notifications/audio.sh index 7af7391..9a5a9db 100755 --- a/utils/notifications/audio.sh +++ b/utils/notifications/audio.sh @@ -9,10 +9,10 @@ id=1527 # HACK: dirty but works case $1 in "audio_up") - notify-send -c Audio -r $id -i ~/.config/custom_icons/audio.png "Output Audio" "Up to $audio_percentage%" + notify-send -c Audio -r $id -i ~/.config/custom_icons/audio.png "Output Audio volume" "󰶼 Up to $audio_percentage% 󰶼" ;; "audio_down") - notify-send -c Audio -r $id -i ~/.config/custom_icons/audio.png "Output Audio" "Down to $audio_percentage%" + notify-send -c Audio -r $id -i ~/.config/custom_icons/audio.png "Output Audio volume" "󰶹 Down to $audio_percentage% 󰶹" ;; "audio_unmute") notify-send -c Audio -r $id -i ~/.config/custom_icons/audio.png "Output Audio" "Unmuted" diff --git a/utils/notifications/mpd.sh b/utils/notifications/mpd.sh index 01dfd38..d187f7f 100755 --- a/utils/notifications/mpd.sh +++ b/utils/notifications/mpd.sh @@ -9,6 +9,7 @@ notify() { mpc readpicture "$(mpc current -f %file%)" > $icon_file song_title=$(mpc current -f %Title%) song_artist=$(mpc current -f %albumartist%) + song_duration=$(mpc current -f %time%) # check image is_image=$(cat $icon_file | grep volume | grep repeat) @@ -20,10 +21,10 @@ notify() { case $1 in "playing") - notify-send -i $final_icon_route -t 6000 -r $id "Currently playing $song_artist" "$song_title" + notify-send -i $final_icon_route -t 6000 -r $id "'$song_artist' is playing" " $song_title ($song_duration)" ;; "paused") - notify-send -i $final_icon_route -t 6000 -r $id "Player paused" "$song_title" + notify-send -i $final_icon_route -t 6000 -r $id "'$song_artist' is paused" " $song_title ($song_duration)" ;; esac }