summaryrefslogtreecommitdiffhomepage
path: root/WORKSPACE
diff options
context:
space:
mode:
authorNicolas Lacasse <nlacasse@google.com>2018-05-10 09:41:05 -0700
committerShentubot <shentubot@google.com>2018-05-10 09:41:58 -0700
commit0ca020dcb392af89e027767bc83bca729bec1219 (patch)
tree5dd82708c53e016c99c1923d5eb840ff7d9c9f73 /WORKSPACE
parentc97f0978b7ced0a31891fab639cc6c9a80e7fb37 (diff)
Use the go_repository rule from the Gazelle repo.
The one from rules_go is being deprecated. PiperOrigin-RevId: 196128132 Change-Id: I7a4ab32696a1bcd221b0585b7a4e8109462a3609
Diffstat (limited to 'WORKSPACE')
-rw-r--r--WORKSPACE14
1 files changed, 10 insertions, 4 deletions
diff --git a/WORKSPACE b/WORKSPACE
index 35a41f149..925402597 100644
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -1,15 +1,21 @@
-# Depend on the go bazel rules.
+# Load go bazel rules and toolchain.
http_archive(
name = "io_bazel_rules_go",
url = "https://github.com/bazelbuild/rules_go/releases/download/0.12.0/rules_go-0.12.0.tar.gz",
sha256 = "c1f52b8789218bb1542ed362c4f7de7052abcf254d865d96fb7ba6d44bc15ee3",
)
-
-# Load go bazel rules and toolchain.
-load("@io_bazel_rules_go//go:def.bzl", "go_repository", "go_rules_dependencies", "go_register_toolchains")
+load("@io_bazel_rules_go//go:def.bzl", "go_rules_dependencies", "go_register_toolchains")
go_rules_dependencies()
go_register_toolchains(go_version="1.10.2")
+# Load gazelle, which is needed for external go dependencies.
+http_archive(
+ name = "bazel_gazelle",
+ url = "https://github.com/bazelbuild/bazel-gazelle/releases/download/0.12.0/bazel-gazelle-0.12.0.tar.gz",
+ sha256 = "ddedc7aaeb61f2654d7d7d4fd7940052ea992ccdb031b8f9797ed143ac7e8d43",
+)
+load("@bazel_gazelle//:deps.bzl", "go_repository")
+
# Add dependencies on external repositories.
go_repository(
name = "com_github_google_go-cmp",