Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#!/bin/bash
while true
do
current_audio1=$(mpc | grep "%)")
sleep 300
current_audio2=$(mpc | grep "%)")
if [ "$current_audio1" = "$current_audio2" ]
then
sudo poweroff
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment