music: Fix mpd-volume-to-mqtt
Some checks failed
Test / build (push) Failing after 1m1s

This commit is contained in:
polyfloyd 2025-05-14 23:53:40 +02:00
parent 949cdbe7bc
commit e9f31417b7

View file

@ -14,7 +14,7 @@ prev_volume=x
if [ $event = "mixer" ]; then if [ $event = "mixer" ]; then
volume=`mpc volume | sed -nr 's/^volume: ([0-9]+)%$/\1/p'` volume=`mpc volume | sed -nr 's/^volume: ([0-9]+)%$/\1/p'`
if [ "$prev_volume" != "$volume" ]; then if [ "$prev_volume" != "$volume" ]; then
mqtt-simple -h {{ mqtt_internal_host }} -p '{{ music_mqtt_mpd_volume }} -r' -m "$volume" mqtt-simple -h {{ mqtt_internal_host }} -p '{{ music_mqtt_mpd_volume }}' -r -m "$volume"
fi fi
prev_volume=$volume prev_volume=$volume
fi fi