pw_env_setup: Stop using PW_CHECKOUT_ROOT
This variable is no longer set by recipe code (pwrev/65640).
Change-Id: Id63d6f33dfffb9dcb406251b39a7770d676fecc2
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/65740
Reviewed-by: Ted Pudlik <tpudlik@google.com>
Commit-Queue: Rob Mohr <mohrr@google.com>
diff --git a/bootstrap.sh b/bootstrap.sh
index 99dcad0..75da8d9 100644
--- a/bootstrap.sh
+++ b/bootstrap.sh
@@ -18,20 +18,8 @@
$(command -v python3 || command -v python2 || command -v python) -c "import os.path; print(os.path.abspath('$@'))"
}
-# Users are not expected to set PW_CHECKOUT_ROOT, it's only used because it
-# seems to be impossible to reliably determine the path to a sourced file in
-# dash when sourced from a dash script instead of a dash interactive prompt.
-# To reinforce that users should not be using PW_CHECKOUT_ROOT, it is cleared
-# here after it is used, and other pw tools will complain if they see that
-# variable set.
-# TODO(mohrr) find out a way to do this without PW_CHECKOUT_ROOT.
-if test -n "$PW_CHECKOUT_ROOT"; then
- _PW_BOOTSTRAP_PATH="$(_bootstrap_abspath "$PW_CHECKOUT_ROOT/bootstrap.sh")"
- # Downstream projects need to set PW_CHECKOUT_ROOT to point to Pigweed if
- # they're using Pigweed's CI/CQ system.
- unset PW_CHECKOUT_ROOT
# Shell: bash.
-elif test -n "$BASH"; then
+if test -n "$BASH"; then
_PW_BOOTSTRAP_PATH="$(_bootstrap_abspath "$BASH_SOURCE")"
# Shell: zsh.
elif test -n "$ZSH_NAME"; then