1
0
Fork 0

togmic: add script

This commit is contained in:
Luca Bilke 2025-01-08 16:22:25 +01:00
parent 32b277c8c9
commit 2bffbf2259
Signed by: luca
GPG key ID: F6E11C9BAA7C82F5

View file

@ -0,0 +1,15 @@
#!/bin/sh
muted() {
pactl get-source-mute @DEFAULT_SOURCE@ | awk '{print $2}'
}
pactl set-source-mute @DEFAULT_SOURCE@ toggle
if [ "$(muted)" = "yes" ]; then
notify-send -h string:x-dunst-stack-tag:"togmic" \
"Microphone Muted" -i mic-off
else
notify-send -h string:x-dunst-stack-tag:"togmic" \
"Microphone Unmuted" -i mic-ready
fi