fix bar paths
This commit is contained in:
parent
8252169862
commit
3aa79de68b
7
env/wm/extras/bar/formatter.bash
vendored
7
env/wm/extras/bar/formatter.bash
vendored
|
@ -1,13 +1,12 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source "$DOTFILES_PATH/variables.bash"
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
|
||||
# export BAR_LOG="$PWD/bar.log"
|
||||
# echo -e "BEGIN BAR LOG\n" > "$BAR_LOG"
|
||||
|
||||
reload_colors() {
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
source "$BAR_PATH/colors.bash"
|
||||
}
|
||||
|
||||
# trap reload_colors SIGUSR1
|
||||
|
@ -27,12 +26,12 @@ register_bar_module() {
|
|||
MODULE_INIT[$1]=$4
|
||||
${MODULE_INIT[$1]} &
|
||||
PID=$!
|
||||
echo $PID > "$DOTFILES_PATH/wm/extras/bar/modules/$3.pid"
|
||||
echo $PID > "$BAR_PATH/modules/$3.pid"
|
||||
# echo -e "Registered Bar Module: $1 $2 $3 $4 with PID $PID" >> "$BAR_LOG"
|
||||
}
|
||||
export -f register_bar_module
|
||||
|
||||
for f in "$DOTFILES_PATH/wm/extras/bar/modules/"*-bm.bash; do
|
||||
for f in "$BAR_PATH/modules/"*-bm.bash; do
|
||||
source "$f"
|
||||
done
|
||||
|
||||
|
|
4
env/wm/extras/bar/modules/bspwm-bm.bash
vendored
4
env/wm/extras/bar/modules/bspwm-bm.bash
vendored
|
@ -1,8 +1,8 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source "$DOTFILES_PATH/variables.bash"
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
source "$DOTFILES_PATH/wm/extras/bar/modules/module.bash"
|
||||
source "$BAR_PATH/colors.bash"
|
||||
source "$BAR_PATH/modules/module.bash"
|
||||
|
||||
PRIORITY=25000
|
||||
|
||||
|
|
2
env/wm/extras/bar/modules/clock-bm.bash
vendored
2
env/wm/extras/bar/modules/clock-bm.bash
vendored
|
@ -1,7 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source "$DOTFILES_PATH/variables.bash"
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
source "$BAR_PATH/colors.bash"
|
||||
|
||||
PRIORITY=38000
|
||||
|
||||
|
|
2
env/wm/extras/bar/modules/date-bm.bash
vendored
2
env/wm/extras/bar/modules/date-bm.bash
vendored
|
@ -1,7 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source "$DOTFILES_PATH/variables.bash"
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
source "$BAR_PATH/colors.bash"
|
||||
|
||||
PRIORITY=35000
|
||||
|
||||
|
|
17
env/wm/extras/bar/modules/module.bash
vendored
17
env/wm/extras/bar/modules/module.bash
vendored
|
@ -1,17 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source "$DOTFILES_PATH/variables.bash"
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
|
||||
reserve_bar_module_pid() {
|
||||
FILE="$DOTFILES_PATH/wm/extras/bar/modules/$1.bm.pid"
|
||||
if [[ -f "$FILE" ]]; then
|
||||
|
||||
return 1
|
||||
else
|
||||
echo "Starting bar module $1 witrh PID $!"
|
||||
$2 &
|
||||
return 0
|
||||
fi
|
||||
}
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source "$DOTFILES_PATH/variables.bash"
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
source "$BAR_PATH/colors.bash"
|
||||
|
||||
PRIORITY=12000
|
||||
|
||||
|
|
6
env/wm/extras/bar/start.bash
vendored
6
env/wm/extras/bar/start.bash
vendored
|
@ -10,7 +10,7 @@ function killbar() {
|
|||
else
|
||||
bspc config -m $(bspc query -M | head -n 1) bottom_padding "0"
|
||||
fi
|
||||
for f in $(ls "$DOTFILES_PATH"/wm/extras/bar/modules/*.pid 2>/dev/null); do
|
||||
for f in $(ls "$BAR_PATH"/modules/*.pid 2>/dev/null); do
|
||||
# echo "KILLING MODULE PROCESS $f WITH PID $(cat "$f")"
|
||||
# kill -SIGTERM $(cat "$f")
|
||||
rm "$f"
|
||||
|
@ -42,7 +42,7 @@ else
|
|||
BAR_B="-b"
|
||||
fi
|
||||
|
||||
source "$DOTFILES_PATH/wm/extras/bar/colors.bash"
|
||||
source "$BAR_PATH/colors.bash"
|
||||
|
||||
cat "$BAR_FIFO" | "$DOTFILES_PATH/wm/extras/bar/formatter.bash" | \
|
||||
cat "$BAR_FIFO" | "$BAR_PATH/formatter.bash" | \
|
||||
lemonbar $BAR_B -g "$WIDTH"x"$BAR_HEIGHT"+"$BAR_MARGIN"+"$POS_Y" -u "$BAR_BORDER_WIDTH" -f "$BAR_FONT_FAMILY" -F "$COLOR_FOREGROUND" -B"$COLOR_BACKGROUND" -n "$BAR_WID"
|
||||
|
|
2
env/x/xinitrc
vendored
2
env/x/xinitrc
vendored
|
@ -17,7 +17,7 @@ xset s off &
|
|||
|
||||
# start the bar if we want it
|
||||
if [ "$BAR_ON_XINIT" -eq 1 ]; then
|
||||
"$DOTFILES_PATH/wm/extras/bar/start.bash" &
|
||||
"$BAR_PATH/start.bash" &
|
||||
fi
|
||||
|
||||
# fire up wm
|
||||
|
|
|
@ -41,4 +41,5 @@ if [ -a "$HOME/.bashrc_env" ]; then
|
|||
fi
|
||||
|
||||
# various paths that are used in the dotfiles
|
||||
BAR_PATH="$DOTFILES_PATH/env/wm/extras/bar"
|
||||
|
||||
|
|
Reference in a new issue