scripts: declare ROOT closer to where it's used, and some DRY changes
This also prevents shellcheck from complaining about a possibly undefined variable. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@@ -22,7 +22,10 @@ set -o errexit
|
||||
set -o nounset
|
||||
set -o pipefail
|
||||
|
||||
source "$(dirname "${BASH_SOURCE[0]}")/build-utils.sh"
|
||||
basedir="$(dirname "${BASH_SOURCE[0]}")"
|
||||
source "${basedir}/build-utils.sh"
|
||||
|
||||
ROOT="$( cd "${basedir}" && pwd )"/..
|
||||
cd "${ROOT}"
|
||||
|
||||
# Make sure output directory is clean.
|
||||
|
||||
Reference in New Issue
Block a user