Skip to content
Snippets Groups Projects
Commit 5bc91a64 authored by Henrik tom Wörden's avatar Henrik tom Wörden
Browse files

MAINT: use better code for setting UTILSPATH

parent 43533a78
No related branches found
No related tags found
No related merge requests found
...@@ -24,6 +24,11 @@ ...@@ -24,6 +24,11 @@
# Dump a database with all procedures, permissions, structure and data # Dump a database with all procedures, permissions, structure and data
if [ -z "$UTILSPATH" ]; then
UTILSPATH="$(realpath $(dirname $0))"
export UTILSPATH
fi
# The directory which the dump is to be stored to. Do not change it here. Use # The directory which the dump is to be stored to. Do not change it here. Use
# the --backupdir=./my/dir/ option or an environment variable instead. # the --backupdir=./my/dir/ option or an environment variable instead.
BACKUPDIR="${BACKUPDIR:-../backup}" BACKUPDIR="${BACKUPDIR:-../backup}"
...@@ -58,7 +63,6 @@ backup: ...@@ -58,7 +63,6 @@ backup:
EOF EOF
) )
UTILS_PATH=`dirname "$(realpath $0)"`
# Load settings from .config and defaults ##################################### # Load settings from .config and defaults #####################################
. $UTILS_PATH/load_settings.sh . $UTILS_PATH/load_settings.sh
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment