2023-10-05 10:09:04 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2024-01-01 08:54:32 -01:00
|
|
|
## Copyright (C) 2020-2024 Aditya Shakya <adi1090x@gmail.com>
|
2023-10-05 10:09:04 +00:00
|
|
|
|
|
|
|
## Files and Directories
|
|
|
|
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
|
|
|
|
PFILE="$DIR/.panel"
|
|
|
|
|
|
|
|
## Launch polybar or tint2 accordingly
|
|
|
|
launch_bar() {
|
|
|
|
CPANEL="`cat $PFILE`"
|
|
|
|
|
|
|
|
if [[ "$CPANEL" == 'polybar' ]]; then
|
|
|
|
bash "$DIR"/polybar.sh
|
|
|
|
elif [[ "$CPANEL" == 'tint2' ]]; then
|
|
|
|
bash "$DIR"/tint2.sh
|
|
|
|
else
|
|
|
|
bash "$DIR"/polybar.sh
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
# Execute function
|
|
|
|
launch_bar
|