]> source.dussan.org Git - jgit.git/commitdiff
Use bazelisk to switch between used bazel version 84/143584/2
authorDavid Ostrovsky <david@ostrovsky.org>
Sat, 8 Jun 2019 15:33:28 +0000 (17:33 +0200)
committerMatthias Sohn <matthias.sohn@sap.com>
Mon, 10 Jun 2019 18:44:51 +0000 (20:44 +0200)
Bazelisk is utility to switch to the right Bazel version, that we
used to have with Buck build tool: [1].

Bazelisk will download the right Bazel version only once and will use
it in subsequent calls:

  $ bazelisk build :release
  2019/06/06 16:22:15 Downloading \
  https://releases.bazel.build/0.26.1/release/bazel-0.26.1-linux-x86_64...

Bazelisk is storing the binaries in user's cache directory: [2], e.g.
on Linux OS:

  $ ls -1 ~/.cache/bazelisk/bin
  bazel-0.26.1-linux-x86_64

* [1] https://github.com/bazelbuild/bazelisk
* [2] https://golang.org/pkg/os/#UserCacheDir

Change-Id: Ia9180fb75f8cc17a0a0232622cf33a13bfad6b60
Signed-off-by: David Ostrovsky <david@ostrovsky.org>
.bazelversion [new file with mode: 0644]

diff --git a/.bazelversion b/.bazelversion
new file mode 100644 (file)
index 0000000..30f6cf8
--- /dev/null
@@ -0,0 +1 @@
+0.26.1