CLI config/dotfiles
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
947 B

  1. #! /bin/sh
  2. . ~/.config/bspwm/panel/panel.conf
  3. if xdo id -a "$PANEL_WM_NAME" > /dev/null; then
  4. printf "%s\n" "The panel is already running." >&2
  5. exit 1
  6. fi
  7. trap 'trap - TERM; kill 0' INT TERM QUIT EXIT
  8. [ -e "$PANEL_FIFO" ] && rm "$PANEL_FIFO"
  9. mkfifo "$PANEL_FIFO"
  10. bspc config top_padding $PANEL_HEIGHT
  11. xtitle -sf 'T%s\n' | sed -u 's/^\(.................................................\).*\(..........................\)/\1...\2/' > "$PANEL_FIFO" &
  12. bspc subscribe report > "$PANEL_FIFO" &
  13. tick > "$PANEL_FIFO" &
  14. while true; do [ -f /tmp/djsissom-jackmute ] && echo 'P' > "$PANEL_FIFO" || echo 'P' > "$PANEL_FIFO"; sleep 0.1; done &
  15. ~/.config/bspwm/panel/panel_bar < "$PANEL_FIFO" | lemonbar -n "$PANEL_WM_NAME" -g "x$PANEL_HEIGHT" -a 20 -B "#BF000000" -F "#FF9A875F" -f "$PANEL_FONT" -f "$PANEL_FONT2" -f "$PANEL_FONT3" | sh &
  16. wid=$(xdo id -m -a "$PANEL_WM_NAME")
  17. xdo above -t $(xdo id -N Bspwm -n root | sort | head -n 1) $wid
  18. wait