dotfiles/etc/acpi/toggle_mute.sh
2023-10-03 13:56:53 +02:00

14 lines
235 B
Bash
Executable File

#!/usr/bin/bash
sinks=$(pactl list sinks short | grep RUNNING | awk '{ print $1 }')
if [ -z "$sinks" ]; then
sinks=$(pactl get-default-sink)
fi
echo "$sinks"
for SINK in $sinks
do
pactl set-sink-mute "${SINK}" toggle
done