summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Barrett <spalf0@gmail.com>2015-10-15 00:40:06 -0500
committerTom Barrett <spalf0@gmail.com>2015-10-15 00:40:06 -0500
commit02e347dffd0ca14ca5dfc23285e24e2107d51782 (patch)
treee42750f41488682eb83e752695d4a0b0132cf99c
parent852439ee965bfa3886ea8fec360dab12dbf812bc (diff)
Create status.sh
-rw-r--r--i3/status.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/i3/status.sh b/i3/status.sh
new file mode 100644
index 0000000..ce3c08a
--- /dev/null
+++ b/i3/status.sh
@@ -0,0 +1,16 @@
+#!/bin/sh
+# shell script to prepend i3status with more stuff
+
+i3status | while :
+do
+ read line
+ MPCSTAT=`mpc | grep -v '^volume:'`
+ if [ -z "${MPCSTAT}" ]; then
+ echo "$line" || exit 1
+ else
+ MPCSTAT=`echo "${MPCSTAT}" | sed 's, *, ,g; 1h;1d;2G' | paste -d' ' -s -`
+ echo "${MPCSTAT} | $line" || exit 1
+ fi
+done
+
+