From cf38eb4ace5de0e2f2e858754d29085778020f74 Mon Sep 17 00:00:00 2001 From: Deon Spengler Date: Sat, 25 Mar 2017 08:57:12 +0200 Subject: [PATCH] fixed formatting --- .config/bspwm/panel | 96 ++++++++++++++++++++++----------------------- 1 file changed, 48 insertions(+), 48 deletions(-) diff --git a/.config/bspwm/panel b/.config/bspwm/panel index fa8f7e1..fe53958 100755 --- a/.config/bspwm/panel +++ b/.config/bspwm/panel @@ -10,8 +10,8 @@ COLOR_GREY2="#a7a5a5" COLOR_GREY3="#504e4e" if xdo id -a "$PANEL_WM_NAME" > /dev/null ; then - printf "%s\n" "The panel is already running." >&2 - exit 1 + printf "%s\n" "The panel is already running." >&2 + exit 1 fi trap 'trap - TERM; kill 0' INT TERM QUIT EXIT @@ -26,59 +26,59 @@ bspc config top_padding $PANEL_HEIGHT bspc subscribe report > "$PANEL_FIFO" & while read -r line ; do - case $line in - S*) - # conky output - sys="${line#?}" - ;; - W*) - # bspwm's state - wm="" - IFS=':' + case $line in + S*) + # conky output + sys="${line#?}" + ;; + W*) + # bspwm's state + wm="" + IFS=':' mon=0 - set -- ${line#?} - while [ $# -gt 0 ] ; do - item=$1 - name=${item#?} - case $item in - [mM]*) + set -- ${line#?} + while [ $# -gt 0 ] ; do + item=$1 + name=${item#?} + case $item in + [mM]*) if [ $num_mon -ge 2 ]; then mon=$((mon+1)) if [ $mon -gt 1 ]; then wm="${wm}%{F${COLOR_GREY2}}%{B${COLOR_BLACK}};" fi fi - ;; - [fFoOuU]*) - case $item in - f*) - # free desktop - FG=$COLOR_GREY2 - BG=$COLOR_BLACK - ;; - F*) - # focused free desktop - FG=$COLOR_GREY1 - BG=$COLOR_GREY3 - ;; - o*) - # occupied desktop - FG=$COLOR_GREY2 - BG=$COLOR_BLACK - ;; - O*) - # focused occupied desktop - FG=$COLOR_GREY1 - BG=$COLOR_GREY3 - ;; - esac - wm="${wm}%{F${COLOR_GREY2}}%{B${BG}}%{F${FG}}%{A:bspc desktop -f ${name}:} ${name}%{A}%{F${BG}}%{B${COLOR_GREY2}}" - ;; - esac - shift - done - ;; - esac + ;; + [fFoOuU]*) + case $item in + f*) + # free desktop + FG=$COLOR_GREY2 + BG=$COLOR_BLACK + ;; + F*) + # focused free desktop + FG=$COLOR_GREY1 + BG=$COLOR_GREY3 + ;; + o*) + # occupied desktop + FG=$COLOR_GREY2 + BG=$COLOR_BLACK + ;; + O*) + # focused occupied desktop + FG=$COLOR_GREY1 + BG=$COLOR_GREY3 + ;; + esac + wm="${wm}%{F${COLOR_GREY2}}%{B${BG}}%{F${FG}}%{A:bspc desktop -f ${name}:} ${name}%{A}%{F${BG}}%{B${COLOR_GREY2}}" + ;; + esac + shift + done + ;; + esac while IFS=';' read -ra array; do bar=""