You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using bazelisk v1.17.0, changing BAZELISK_FORMAT_URL does not trigger re-downloading Bazel if the same version number of Bazel has previously been downloaded from anywhere.
# Start off clean
rm -f .bazelversion
rm -f .bazeliskrc
rm -rf ~/.cache/bazelisk/downloads/bazelbuild
# Download official/upstream Bazel 6.3.1
USE_BAZEL_VERSION=6.3.1 bazelisk --version
# Outputs:
# 2023/08/11 10:05:46 Downloading https://releases.bazel.build/6.3.1/release/bazel-6.3.1-linux-x86_64...
# bazel 6.3.1
# Switch to our internally-built and published URL
cat > .bazeliskrc <<EOL
BAZELISK_FORMAT_URL=<our internal URL>
USE_BAZEL_VERSION=6.3.1
EOL
bazelisk --version
# Outputs:
# bazel 6.3.1
# We expect this to download from our internal URL, but it does not
Workaround: we can use BAZELISK_BASE_URL, but then we have to conform to the usual URL format.
Changing BAZELISK_BASE_URL properly re-downloads - the code here changes the download directory if BaseURLEnv is set, but not if FormatURLEnv is set.
The text was updated successfully, but these errors were encountered:
Using
bazelisk v1.17.0
, changingBAZELISK_FORMAT_URL
does not trigger re-downloading Bazel if the same version number of Bazel has previously been downloaded from anywhere.Workaround: we can use
BAZELISK_BASE_URL
, but then we have to conform to the usual URL format.Changing
BAZELISK_BASE_URL
properly re-downloads - the code here changes the download directory ifBaseURLEnv
is set, but not ifFormatURLEnv
is set.The text was updated successfully, but these errors were encountered: