X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=scripts%2Fcore%2Flaunch_feisty_meow.sh;h=9e818341eec7d760db4755824f029df06f53b386;hb=63ea779000a06dd59febb62501f0e97812037a31;hp=70b1b0cafa0c26654b74526c4259200d2eba0bbe;hpb=9fd687b2a9082cc5ce244f779d3f259ea6753216;p=feisty_meow.git diff --git a/scripts/core/launch_feisty_meow.sh b/scripts/core/launch_feisty_meow.sh index 70b1b0ca..9e818341 100644 --- a/scripts/core/launch_feisty_meow.sh +++ b/scripts/core/launch_feisty_meow.sh @@ -18,6 +18,18 @@ ############## +# some preconditions we want to establish before loading anything... + +# make sure that aliases can be used in non-interactive shells. +shopt -s expand_aliases + +# patch the user variable if we were launched by one of our cron jobs. +if [ -z "$USER" -a ! -z "$CRONUSER" ]; then + export USER="$CRONUSER" +fi + +############## + export ERROR_OCCURRED= # there have been no errors to start with, at least. we will set this # to non-empty if something bad happens. @@ -46,7 +58,7 @@ if [ -z "$FEISTY_MEOW_LOADING_DOCK" ]; then source "$FEISTY_MEOW_VARIABLES_LOADING_FILE" # Set up the temporary directory. - source $FEISTY_MEOW_SCRIPTS/core/create_tempdir.sh + source "$FEISTY_MEOW_SCRIPTS/core/create_tempdir.sh" fi @@ -55,14 +67,13 @@ fi # load the larger body of standard feisty meow variables into the environment. # we actually want this to always run also; it will decide what variables need # to be set again. -source $FEISTY_MEOW_SCRIPTS/core/variables.sh +source "$FEISTY_MEOW_SCRIPTS/core/variables.sh" ############## # include helpful functions. we do this every time rather than making it part # of variable initialization, because functions cannot be exported to -# sub-shells in bash (much like aliases cannot, to our infinite chagrin after -# having migrated from korn shell...). +# sub-shells in bash. source "$FEISTY_MEOW_SCRIPTS/core/functions.sh" # load some helper methods for the terminal which we'll use below.