Skip to content
Snippets Groups Projects
Unverified Commit f5c84576 authored by Daniel's avatar Daniel
Browse files

FIX: Existing environment variables have higher priority than config

parent d135061d
Branches
Tags
No related merge requests found
......@@ -33,6 +33,9 @@ if [ -z "$MAINPATH" ]; then
export MAINPATH
fi
# Make a backup of the important environment variables.
my_env=$(export -p | grep -E '(MYSQL|DATABASE)')
source "$MAINPATH/config.defaults"
if [[ -r "$MAINPATH/.config" ]] ; then
......@@ -47,6 +50,9 @@ if [[ -z "$MYSQL_CMD" ]] ; then
exit 1
fi
# Restore backup.
eval "$my_env"
export MYSQL_CMD
export MYSQLDUMP_CMD
export MYSQLADMIN_CMD
......
......@@ -97,7 +97,7 @@ function _setup_mytap() {
echo MyTAB framework is already installed [OK]
return 0
fi
echo -n "Installing MyTAB framework ... "
echo -n "Installing MyTAP framework ... "
pushd libs > /dev/null
unzip -u mytap*.zip > /dev/null
pushd mytap*/ > /dev/null
......@@ -105,7 +105,7 @@ function _setup_mytap() {
popd > /dev/null
rm -r mytap*/
popd > /dev/null
echo [DONE]
echo "[DONE]"
}
function install_db() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment