summaryrefslogtreecommitdiff
path: root/lib/load-configuration
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2020-01-30 13:21:30 +0100
committerErich Eckner <git@eckner.net>2020-01-30 13:21:30 +0100
commit146be515f66232eb8c8129d0292eae7f07dbd2cb (patch)
tree828a3f19406e065e55cec1f837c3e766b6722360 /lib/load-configuration
parent9bd51c9d12fd51c72b28d01bc104bfd03007a9f2 (diff)
downloadbuilder-146be515f66232eb8c8129d0292eae7f07dbd2cb.tar.xz
lib/load-configuration: set correct base_dir for running intentions
Diffstat (limited to 'lib/load-configuration')
-rwxr-xr-xlib/load-configuration4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/load-configuration b/lib/load-configuration
index 8426b78..ab0a183 100755
--- a/lib/load-configuration
+++ b/lib/load-configuration
@@ -47,6 +47,10 @@ fi
if [ -z "${base_dir}" ]; then
base_dir=$(printf '%s/..' "$(dirname "$(readlink -f "$0")")")
+ if printf '%s\n' "${0}" \
+ | grep -qx '.*/intention\.[0-9]\+'; then
+ base_dir="${base_dir}/.."
+ fi
fi
base_dir=$(