diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2020-02-24 03:39:44 -0800 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2020-02-24 03:39:44 -0800 |
| commit | 88fd9c416be0f5fe1e5fd48ba7c27d4d1e25261c (patch) | |
| tree | cfe311fb81c1d12e46b08de175a6296f0aed7a0d /scripts/bbstartup | |
| parent | 304cbddf730b86dec2b3d7c414fd0b9a38c69d76 (diff) | |
Moved bbstartup into a script, renamed helper/ -> scripts/, and added
bbshutdown script. Also tweaked some of the precedence.
Diffstat (limited to 'scripts/bbstartup')
| -rwxr-xr-x | scripts/bbstartup | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/scripts/bbstartup b/scripts/bbstartup new file mode 100755 index 0000000..40de50b --- /dev/null +++ b/scripts/bbstartup @@ -0,0 +1,15 @@ +#!/bin/sh +# This file contains the script that is run when bb launches + +[ ! -d "$XDG_DATA_HOME/bb" ] && mkdir -p "$XDG_DATA_HOME/bb" + +# Load key bindings +if [ "$BBPATH" ]; then + cat "$BBPATH/bindings.bb" "$XDG_CONFIG_HOME/bb/bindings.bb" +else + cat "$sysconfdir/xdg/bb/bindings.bb" "$XDG_CONFIG_HOME/bb/bindings.bb" +fi 2>/dev/null | awk '/^#/ {next} /^[^ ]/ {printf "\0bind:"} {print $0} END {printf "\0"}' >> "$BBCMD" + +if [ -e "$XDG_DATA_HOME/bb/settings.sh" ]; then + . "$XDG_DATA_HOME/bb/settings.sh" +fi |
