2015-04-12 21:19:15 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
if mpc -q; then
|
|
|
|
case "$(mpc status | sed -n '2s/\[\(\w*\)\].*/\1/p')" in
|
|
|
|
"playing") icon="<icon=music/play.xpm/>" ;;
|
2015-04-14 01:18:05 +02:00
|
|
|
*) icon="<icon=music/pause.xpm/>" ;;
|
2015-04-12 21:19:15 +02:00
|
|
|
esac
|
2015-04-14 01:18:05 +02:00
|
|
|
echo '<action=`urxvtc -e "ncmpcpp" "-c" "~/.config/ncmpcpp/config"`>'"$icon"'</action>'
|
2015-04-12 21:19:15 +02:00
|
|
|
fi
|
|
|
|
|