1
0
mirror of https://github.com/dcarrillo/dotfiles.git synced 2025-07-04 04:09:26 +00:00

Make shell scripts (almost) POSIX compliant

This commit is contained in:
2019-11-17 17:29:34 +01:00
parent 9d6bbeae7c
commit 5211d4aacb
6 changed files with 38 additions and 55 deletions

View File

@ -1,10 +1,11 @@
#!/usr/bin/env bash
killall -q polybar
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
while pgrep -u "$(id -u)" -x polybar >/dev/null; do sleep 1; done
export TERMINAL_CMD="tilix --profile orange --new-process -e"
export WM_CONTROL="$(dirname $0)/scripts/switch_window_state"
WM_CONTROL="$(dirname "$0")/scripts/switch_window_state"
export WM_CONTROL
for monitor in $(polybar --list-monitors | cut -d":" -f1); do
export MONITOR=$monitor