From cce1842b90afcb1a7a6593477b2ca8f93e5fea22 Mon Sep 17 00:00:00 2001 From: Philipp Stephani Date: Thu, 6 Aug 2026 15:29:44 +0200 Subject: [PATCH] Document that USE_BAZEL_VERSION must be nonempty MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If it’s empty, then it won’t be used, which is occasionally useful in cases where an environment variable can be set but not unset. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e11549da..faf78180 100644 --- a/README.md +++ b/README.md @@ -44,7 +44,7 @@ The documentation below describes the newer Go version only. ## How does Bazelisk know which Bazel version to run? It uses a simple algorithm: -- If the environment variable `USE_BAZEL_VERSION` is set, it will use the version specified in the value. +- If the environment variable `USE_BAZEL_VERSION` is set to a nonempty value, it will use the version specified in the value. - Otherwise, if a `.bazeliskrc` file exists in the workspace root and contains the `USE_BAZEL_VERSION` variable, this version will be used. - Otherwise, if a `.bazelversion` file exists in the current directory or recursively any parent directory, it will read the file and use the version specified in it. - Otherwise, if the environment variable `USE_BAZEL_FALLBACK_VERSION` is set to one of the following formats: