Skip to content

Commit

Permalink
Merge pull request #23 from tofuutils/fix/homebrew
Browse files Browse the repository at this point in the history
feat: rename library files to fix homebrew installation
  • Loading branch information
kvendingoldo authored Jan 3, 2024
2 parents 58b75c7 + a869a93 commit 6281cf3
Show file tree
Hide file tree
Showing 24 changed files with 66 additions and 69 deletions.
6 changes: 3 additions & 3 deletions bin/tofu
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && >&2 echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && >&2 echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions bin/tofuenv
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && >&2 echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && >&2 echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion lib/helpers.sh → lib/tofuenv-helpers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ if [ "${TOFUENV_DEBUG:-0}" -gt 0 ]; then
fi;

function load_bashlog () {
source "${TOFUENV_ROOT}/lib/bashlog.sh";
source "${TOFUENV_ROOT}/lib/tofuenv-bashlog.sh";
};
export -f load_bashlog;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv---version
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-exec
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
13 changes: 5 additions & 8 deletions libexec/tofuenv-install
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down Expand Up @@ -234,11 +234,8 @@ elif [[ -f "${TOFUENV_CONFIG_DIR}/use-gpgv" ]]; then

download_signature;
if [[ "${trust_tofuenv}" == 'yes' ]]; then
${gpgv_command} \
--keyring "${TOFUENV_ROOT}/share/hashicorp-keys.pgp" \
"${download_tmp}/${shasums_sig}" \
"${download_tmp}/${shasums_name}" \
|| log 'error' 'PGP signature rejected';
log 'error' 'Opentofu does not currently support PGP signatures.';

else
${gpgv_command} \
"${download_tmp}/${shasums_sig}" \
Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-list
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-list-remote
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-min-required
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-pin
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-resolve-version
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-uninstall
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-use
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-version-file
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions libexec/tofuenv-version-name
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
Binary file removed share/hashicorp-keys.pgp
Binary file not shown.
6 changes: 3 additions & 3 deletions test/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions test/test_install_and_use.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions test/test_list.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions test/test_symlink.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions test/test_uninstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions test/test_use_latestallowed.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down
6 changes: 3 additions & 3 deletions test/test_use_minrequired.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export TOFUENV_ROOT;
if [ -n "${TOFUENV_HELPERS:-""}" ]; then
log 'debug' 'TOFUENV_HELPERS is set, not sourcing helpers again';
else
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
if source "${TOFUENV_ROOT}/lib/helpers.sh"; then
[ "${TOFUENV_DEBUG:-0}" -gt 0 ] && echo "[DEBUG] Sourcing helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
if source "${TOFUENV_ROOT}/lib/tofuenv-helpers.sh"; then
log 'debug' 'Helpers sourced successfully';
else
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/helpers.sh";
early_death "Failed to source helpers from ${TOFUENV_ROOT}/lib/tofuenv-helpers.sh";
fi;
fi;

Expand Down

0 comments on commit 6281cf3

Please sign in to comment.