-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Open
Labels
P2We'll consider working on this in future. (Assignee optional)We'll consider working on this in future. (Assignee optional)incompatible-changeIncompatible/breaking changeIncompatible/breaking changeteam-Rules-ServerIssues for serverside rules included with BazelIssues for serverside rules included with Bazeltype: process
Description
Flag: --incompatible_load_proto_rules_from_bzl
Available since: 0.29
Will be flipped in: TBD
Tracking issue: #8891
proto_library and proto_lang_toolchain have to be loaded from @rules_proto.
For example, if you are usingproto_library, add the following load statement to your BUILD/bzl file.
load("@rules_proto//proto:defs.bzl", "proto_library")You can use the following buildifier command to automate the changes to your BUILD/bzl files:
buildifier --lint=fix --warnings=native-proto <path/to/BUILD>
You will have to add proto_library to your WORKSPACE file as well:
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_proto",
sha256 = "602e7161d9195e50246177e7c55b2f39950a9cf7366f74ed5f22fd45750cd208",
strip_prefix = "rules_proto-97d8af4dc474595af3900dd85cb3a29ad28cc313",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_proto/archive/97d8af4dc474595af3900dd85cb3a29ad28cc313.tar.gz",
"https://github.com/bazelbuild/rules_proto/archive/97d8af4dc474595af3900dd85cb3a29ad28cc313.tar.gz",
],
)
load("@rules_proto//proto:repositories.bzl", "rules_proto_dependencies", "rules_proto_toolchains")
rules_proto_dependencies()
rules_proto_toolchains()Reactions are currently unavailable
Metadata
Metadata
Labels
P2We'll consider working on this in future. (Assignee optional)We'll consider working on this in future. (Assignee optional)incompatible-changeIncompatible/breaking changeIncompatible/breaking changeteam-Rules-ServerIssues for serverside rules included with BazelIssues for serverside rules included with Bazeltype: process