aboutsummaryrefslogtreecommitdiff
path: root/Panel/lemonbar/music
diff options
context:
space:
mode:
authorVasil Zlatanov <vasil.zlatanov@gmail.com>2016-12-28 21:14:46 +0000
committerVasil Zlatanov <vasil.zlatanov@gmail.com>2016-12-28 21:14:46 +0000
commit43a2a7ab2dadb3deb8867831b120c50572218d6e (patch)
tree15a09757d37bd7405ad417e7d6d2125dbf448256 /Panel/lemonbar/music
parent1238eaf331f6b476a938dbf448cb6058e7d93203 (diff)
downloaddotfiles-43a2a7ab2dadb3deb8867831b120c50572218d6e.tar.gz
dotfiles-43a2a7ab2dadb3deb8867831b120c50572218d6e.tar.bz2
dotfiles-43a2a7ab2dadb3deb8867831b120c50572218d6e.zip
specify mpc host consitently
Diffstat (limited to 'Panel/lemonbar/music')
-rwxr-xr-xPanel/lemonbar/music8
1 files changed, 4 insertions, 4 deletions
diff --git a/Panel/lemonbar/music b/Panel/lemonbar/music
index 2fb91d1..d9e1d45 100755
--- a/Panel/lemonbar/music
+++ b/Panel/lemonbar/music
@@ -2,17 +2,17 @@
while true;do
-new=`mpc current`
+new=`mpc -h 127.0.0.1 current`
-if mpc | grep -q playing; then
+if mpc -h 127.0.0.1 | grep -q playing; then
symbol='p'
else
symbol='P'
fi
echo "$symbol`echo $new | cut --bytes 1-30`"
-echo "K`mpc -h 127.0.0.1 volume | perl -pe 's/^volume://' | perl -pe 's/%$//' | perl -pe 's/^ //'`"
-mpc idle > /dev/null
+echo "K`mpc volume -h 127.0.0.1 | perl -pe 's/^volume://' | perl -pe 's/%$//' | perl -pe 's/^ //'`"
+mpc -h 127.0.0.1 idle > /dev/null
if [ $? -ne 0 ];then
echo 'mpd not alive';
sleep 30;