diff --git a/tool/go b/tool/go index 4d6ed16..3d9bd3c 100755 --- a/tool/go +++ b/tool/go @@ -8,6 +8,8 @@ if [[ "${CI:-}" == "true" && "${NOBASHDEBUG:-}" != "true" ]]; then set -x fi +tsandroid=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )/.." &> /dev/null && pwd ) + # Allow TOOLCHAINDIR to be overridden, as a special case for the fdroid build if [[ -z "${TOOLCHAINDIR}" ]]; then toolchain="$HOME/.cache/tailscale-go" @@ -29,10 +31,13 @@ if [[ -z "${TOOLCHAINDIR}" ]]; then rm -rf "$toolchain" "$toolchain.extracted" fi fi - if [[ ! -d "$toolchain" ]]; then - mkdir -p "$HOME/.cache" - read -r REV