commit e7b21518eba99e6fa5ce6c30f0ca13a5c61f219e
parent a29a68bae3d6c247d27012575e262d22442f0f90
Author: Alexander Balgavy <alexander.balgavy@spaceapplications.com>
Date: Sat, 14 Oct 2023 18:51:09 +0200
dwmblock-volume: indicator for nerd-dictation
Diffstat:
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/scripts/dwmblock-volume b/scripts/dwmblock-volume
@@ -37,8 +37,10 @@ case $(pactl get-source-mute "$source") in
mic_icon='🎤'
;;
esac
+
+pgrep -f nerd-dictation >/dev/null 2>&1 && recording=' ⏺'
mic="$(pactl get-source-volume "$source" \
| head -n 1 \
| awk -v mic_icon="$mic_icon" -F ' / ' '{gsub(" ", "", $2); gsub(" ", "", $4); printf("%s %s %s", mic_icon, $2,$4)}')"
-printf "%s %s" "$volume" "$mic"
+printf "%s %s%s" "$volume" "$mic" "$recording"