summaryrefslogtreecommitdiffstats
path: root/bspwm/.local/bin/panel
diff options
context:
space:
mode:
authorAmin Bandali <me@aminb.org>2014-11-21 22:08:00 -0500
committerAmin Bandali <me@aminb.org>2014-11-21 22:08:00 -0500
commitd760033f89f7284473895b207e1e36b2f934e8b8 (patch)
treebd91c8fe86aea33b8054195bd913f16cb9655fbc /bspwm/.local/bin/panel
parente6915379a3e4dac6a7ea56c6f148042bf9d1a6f3 (diff)
downloadconfigs-d760033f89f7284473895b207e1e36b2f934e8b8.tar.gz
configs-d760033f89f7284473895b207e1e36b2f934e8b8.tar.xz
configs-d760033f89f7284473895b207e1e36b2f934e8b8.zip
new installation setup
Diffstat (limited to 'bspwm/.local/bin/panel')
-rwxr-xr-xbspwm/.local/bin/panel30
1 files changed, 30 insertions, 0 deletions
diff --git a/bspwm/.local/bin/panel b/bspwm/.local/bin/panel
new file mode 100755
index 0000000..a981f43
--- /dev/null
+++ b/bspwm/.local/bin/panel
@@ -0,0 +1,30 @@
+#! /bin/sh
+
+if [ $(pgrep -cx panel) -gt 1 ] ; then
+ printf "%s\n" "The panel is already running." >&2
+ exit 1
+fi
+
+trap 'trap - TERM; kill 0' INT TERM QUIT EXIT
+
+[ -e "$PANEL_FIFO" ] && rm "$PANEL_FIFO"
+mkfifo "$PANEL_FIFO"
+
+bspc config top_padding $PANEL_HEIGHT
+bspc control --subscribe > "$PANEL_FIFO" &
+#xtitle -sf 'T%s' > "$PANEL_FIFO" &
+#clock -sf 'S%a %H:%M' > "$PANEL_FIFO" &
+
+#pamixer --get-volume > /tmp/volinfo
+#if $(pamixer --get-mute) ; then
+ echo ⮝ > /tmp/spkicon
+#else
+# echo ⮟ > /tmp/spkicon
+#fi
+conky > "$PANEL_FIFO" &
+
+. panel_colors
+
+cat "$PANEL_FIFO" | panel_bar | bar -g x$PANEL_HEIGHT -f "$PANEL_FONT_FAMILY1","$PANEL_FONT_FAMILY2" -F "$COLOR_FOREGROUND" -B "$COLOR_BACKGROUND" &
+
+wait