Skip to content
Snippets Groups Projects
Unverified Commit e58daba8 authored by nkakouros's avatar nkakouros Committed by GitHub
Browse files

Update headstart-core.bash

Co-authored by: mehes-kth <mehes@kth.se>
parent 8c12fd46
Branches
Tags
No related merge requests found
......@@ -8,12 +8,15 @@
# Path to the project's root directory
declare -gx PROJECT_DIR
# The `SHELL` env variable is not supported by every shell and bash sets it
# only if it is not set already. To be sure it exists, it is set here.
[[ ! -v BASH ]] || export SHELL=$BASH
# Used for testing
if [[ -v PROJECT_DIR ]]; then
PROJECT_DIR="$PROJECT_DIR"
else
cd "${0%/*}" || exit "$_HEADSTART_EC_GENERR"
PROJECT_DIR="$PWD"
declare -gx PROJECT_DIR="$(cd "$(dirname "$0")" && pwd)"
fi
if [[ ! -v _HEADSTART_SCRIPT_NAME ]]; then # tests may set this directly
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment