aboutsummaryrefslogtreecommitdiff
path: root/ratpoison/panel/monce
diff options
context:
space:
mode:
authorVasil Zlatanov <vasil.zlatanov@gmail.com>2015-03-01 14:09:52 +0100
committerVasil Zlatanov <vasil.zlatanov@gmail.com>2015-03-01 14:09:52 +0100
commitdcfd734112dfbff3ad24c6bdbdea46b9f7919369 (patch)
treee1bb4d1eda7cc2a9596ee89f17b177457deb2a10 /ratpoison/panel/monce
parent2ae2ab7eed7b47af93a0bc4b49f8cfd70d448f82 (diff)
downloaddotfiles-dcfd734112dfbff3ad24c6bdbdea46b9f7919369.tar.gz
dotfiles-dcfd734112dfbff3ad24c6bdbdea46b9f7919369.tar.bz2
dotfiles-dcfd734112dfbff3ad24c6bdbdea46b9f7919369.zip
firefox + panel update
Diffstat (limited to 'ratpoison/panel/monce')
-rwxr-xr-xratpoison/panel/monce25
1 files changed, 25 insertions, 0 deletions
diff --git a/ratpoison/panel/monce b/ratpoison/panel/monce
new file mode 100755
index 0000000..caa316c
--- /dev/null
+++ b/ratpoison/panel/monce
@@ -0,0 +1,25 @@
+#!/bin/sh
+
+
+f=1
+d=30 # width
+
+new=`mpc current`
+if [ "$old" != "$new" ];then
+f=1;
+old="$new"
+fi
+
+
+e=$(expr $f + $d)
+
+if mpc | grep -q playing; then
+symbol='p'
+else
+symbol='P'
+fi
+
+echo "$symbol`echo $new | cut --bytes $f-$e`"
+echo "K`mpc -h 127.0.0.1 volume | perl -pe 's/^volume://' | perl -pe 's/%$//' | perl -pe 's/^ //'`"
+
+