From: Christian Heller Date: Thu, 3 Sep 2026 08:03:45 +0000 (+0000) Subject: Always call _lib.sh from script's directory. X-Git-Url: https://plomlompom.com/repos/%22https:/validator.w3.org/condition?a=commitdiff_plain;h=7a14ed43475c3e4a8eab5946c63023bf44b78cd3;p=confplom Always call _lib.sh from script's directory. --- diff --git a/_lib.sh b/_lib.sh index f9ca73b..26dde06 100644 --- a/_lib.sh +++ b/_lib.sh @@ -1,5 +1,6 @@ set -Ceu SCRIPT_NAME=$0 +cd "$(dirname "${SCRIPT_NAME}")" # constants unlikely to change NAME_DEV=dev diff --git a/chrooted_command.sh b/chrooted_command.sh index 3002bfd..8e0033a 100755 --- a/chrooted_command.sh +++ b/chrooted_command.sh @@ -1,5 +1,5 @@ #!/bin/sh -. ./_lib.sh +. "$(dirname "$0")/_lib.sh" # inputs to confirm usage $# "partition" "root-name" "command" diff --git a/install_debian.sh b/install_debian.sh index 0867be4..6dce243 100755 --- a/install_debian.sh +++ b/install_debian.sh @@ -1,5 +1,5 @@ #!/bin/sh -. ./_lib.sh +. "$(dirname "$0")/_lib.sh" # constants unlikely to change FNAME_INITRD=initrd.img diff --git a/setup_luksvg.sh b/setup_luksvg.sh index 8a651b4..885966c 100755 --- a/setup_luksvg.sh +++ b/setup_luksvg.sh @@ -1,5 +1,5 @@ #!/bin/sh -. ./_lib.sh +. "$(dirname "$0")/_lib.sh" # inputs to confirm usage $# "partition" diff --git a/start_home.sh b/start_home.sh index c4c838f..9eaf55e 100755 --- a/start_home.sh +++ b/start_home.sh @@ -1,6 +1,5 @@ #!/bin/sh -cd "$(dirname "$0")" || exit -. ./_lib.sh +. "$(dirname "$0")/_lib.sh" # constants unlikely to change FNAME_PROFILE=.profile diff --git a/start_root.sh b/start_root.sh index a2de4e0..f87a1fb 100755 --- a/start_root.sh +++ b/start_root.sh @@ -1,6 +1,5 @@ #!/bin/sh -cd "$(dirname "$0")" || exit -. ./_lib.sh +. "$(dirname "$0")/_lib.sh" # constants unlikely to change FNAME_START_HOME=start_home.sh