generated from bazel-contrib/rules-template
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify CI setup and use prebuilt protoc (#90)
- Loading branch information
Showing
8 changed files
with
83 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ bazel-* | |
.bazelrc.user | ||
.idea/ | ||
.ijwb/ | ||
MODULE.bazel.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,25 @@ | ||
# This load statement must be in the docs/ package rather than anything users depend on | ||
# so that the dependency on stardoc doesn't leak to them. | ||
load("@aspect_bazel_lib//lib:docs.bzl", "stardoc_with_diff_test", "update_docs") | ||
load("@rules_proto//proto:proto_lang_toolchain.bzl", "proto_lang_toolchain") | ||
|
||
stardoc_with_diff_test( | ||
name = "defs", | ||
bzl_library_target = "//with_cfg:defs", | ||
) | ||
|
||
update_docs(name = "update") | ||
|
||
# Precompiled proto toolchain for stardoc | ||
proto_lang_toolchain( | ||
name = "protoc_java_toolchain", | ||
command_line = "--java_out=$(OUT)", | ||
progress_message = "Generating java_proto_library %{label}", | ||
runtime = "@protobuf_java//jar", | ||
) | ||
|
||
toolchain( | ||
name = "protoc_java_toolchain.registration", | ||
toolchain = ":protoc_java_toolchain", | ||
toolchain_type = "@rules_java//java/proto:toolchain_type", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
load("@bazel_skylib//lib:modules.bzl", "modules") | ||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_jar") | ||
|
||
def _protobuf_java_repo(): | ||
http_jar( | ||
name = "protobuf_java", | ||
urls = ["https://repo1.maven.org/maven2/com/google/protobuf/protobuf-java/4.26.1/protobuf-java-4.26.1.jar"], | ||
integrity = "sha256-CRkz5YcK+BB0gyb3rOSmc6ynISUxd1QoQvBEtUbxQoI=", | ||
) | ||
|
||
protobuf_java_repo = modules.as_extension(_protobuf_java_repo) |