mirror of
https://github.com/dani-garcia/bw_web_builds.git
synced 2024-10-31 14:54:48 +03:00
23 lines
498 B
Bash
23 lines
498 B
Bash
|
#!/usr/bin/env bash
|
||
|
set -o pipefail -o errexit
|
||
|
BASEDIR=$(dirname "$(readlink -f "$0")")
|
||
|
|
||
|
# Error handling
|
||
|
handle_error() {
|
||
|
read -n1 -r -p "FAILED: line $1, exit code $2. Press any key to exit..." _
|
||
|
exit 1
|
||
|
}
|
||
|
trap 'handle_error $LINENO $?' ERR
|
||
|
|
||
|
# Load default script environment variables
|
||
|
# shellcheck source=.script_env
|
||
|
. "${BASEDIR}/.script_env"
|
||
|
|
||
|
pushd "${VAULT_FOLDER}"
|
||
|
|
||
|
# Apply a patch from the patches directory
|
||
|
# shellcheck source=apply_patches.sh
|
||
|
. "${BASEDIR}/apply_patches.sh"
|
||
|
|
||
|
popd
|