From abd0c2e5113aa46ebb9f83eeb537f21d2b197af1 Mon Sep 17 00:00:00 2001 From: shark Date: Sun, 2 Dec 2018 22:34:17 +0000 Subject: [PATCH] add volume notification --- .config/fish/config.fish | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.config/fish/config.fish b/.config/fish/config.fish index cb39c3b..98c7e17 100644 --- a/.config/fish/config.fish +++ b/.config/fish/config.fish @@ -26,3 +26,10 @@ function ss gnome-screenshot -a -f ~/$timesave > /dev/null 2>&1 echo 'Screenshot saved at ~/'$timesave end + +function getvol + killall notify-osd + set vol (pactl list sinks | grep '^[[:space:]]Volume:' | head -n 1 | tail -n 1 | sed -e 's,.* \([0-9][0-9]*\)%.*,\1,') + notify-send -t 50 'Volume: '$vol'%' + sleep 2 +end \ No newline at end of file