-
Notifications
You must be signed in to change notification settings - Fork 1
/
MODULE.bazel
34 lines (26 loc) · 1.28 KB
/
MODULE.bazel
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
module(
name = "connect-go-example",
version = "1.0.0",
compatibility_level = 1,
)
bazel_dep(name = "buildifier_prebuilt", version = "6.4.0", dev_dependency = True)
bazel_dep(name = "gazelle", version = "0.36.0", dev_dependency = True, repo_name = "bazel_gazelle")
bazel_dep(name = "rules_buf", version = "0.2.0", dev_dependency = True)
bazel_dep(name = "rules_go", version = "0.47.1", dev_dependency = True)
# local_path_override(module_name = "rules_go", path = "../rules_go")
single_version_override(
module_name = "rules_go",
patches = ["import.patch"],
)
go_sdk = use_extension("@rules_go//go:extensions.bzl", "go_sdk")
go_sdk.download(version = "1.22.3")
# Register the Go SDK installed on the host.
go_sdk.host()
go_deps = use_extension("@bazel_gazelle//:extensions.bzl", "go_deps")
go_deps.from_file(go_mod = "//:go.mod")
use_repo(go_deps, "com_connectrpc_connect", "com_connectrpc_grpchealth", "com_connectrpc_grpcreflect", "org_golang_google_protobuf", "org_golang_x_net")
buf = use_extension("@rules_buf//buf:extensions.bzl", "buf")
# See https://buf.build/docs/build-systems/bazel#buf-dependencies
buf.dependency(module = "buf.build/envoyproxy/protoc-gen-validate:eac44469a7af47e7839a7f1f3d7ac004")
# Allow references to labels under @buf_deps
use_repo(buf, "buf_deps")