Buildifier fixes

This commit is contained in:
Adam Liddell 2021-09-21 23:52:09 +01:00
parent 1d110bc6e3
commit 98a39741ed
6 changed files with 7 additions and 9 deletions

View File

@ -265,8 +265,6 @@ load("@io_bazel_rules_scala//scala:toolchains.bzl", "scala_register_toolchains")
scala_register_toolchains()
load("@rules_jvm_external//:defs.bzl", "maven_install")
maven_install(
name = "rules_proto_grpc_scala_maven",
artifacts = MAVEN_ARTIFACTS,

View File

@ -4,12 +4,11 @@ load(
"//:defs.bzl",
"ProtoPluginInfo",
"proto_compile_attrs",
"proto_compile_impl",
)
load("//internal:compile.bzl", "proto_compile")
# Create compile rule
def doc_template_compile_impl(ctx):
def doc_template_compile_impl(ctx): # buildifier: disable=function-docstring
# Load attrs that we pass as args
options = ctx.attr.options
extra_protoc_args = getattr(ctx.attr, "extra_protoc_args", [])
@ -24,7 +23,7 @@ def doc_template_compile_impl(ctx):
ctx.file.template.path,
ctx.attr.name,
]
extra_protoc_files += [ctx.file.template]
extra_protoc_files.append(ctx.file.template)
# Execute with extracted attrs
return proto_compile(ctx, options, extra_protoc_args, extra_protoc_files)

View File

@ -82,6 +82,7 @@ def routeguide_test_matrix(name = "", clients = [], servers = [], database = "//
servers: The list of available routeguide servers.
database: The features list to provide to the test.
tagmap: The dict of tags to apply to specific languages or tests ("lang" or "lang_lang").
skip: Combinations of client and server to skip, e.g. "cpp_js"
Returns:
Nothing.

View File

@ -1,3 +1,4 @@
load("@rules_java//java:defs.bzl", "java_binary")
load("//:defs.bzl", "proto_plugin")
proto_plugin(

View File

@ -2,7 +2,7 @@
load(
"//:repositories.bzl",
"GRPC_VERSION",
"GRPC_VERSION", # @unused
"io_bazel_rules_scala",
"io_grpc_grpc_java",
"rules_jvm_external",

View File

@ -4,12 +4,11 @@ var docCustomRuleTemplateString = mustTemplate(`load(
"//:defs.bzl",
"ProtoPluginInfo",
"proto_compile_attrs",
"proto_compile_impl",
)
load("//internal:compile.bzl", "proto_compile")
# Create compile rule
def {{ .Rule.Name }}_impl(ctx):
def {{ .Rule.Name }}_impl(ctx): # buildifier: disable=function-docstring
# Load attrs that we pass as args
options = ctx.attr.options
extra_protoc_args = getattr(ctx.attr, "extra_protoc_args", [])
@ -24,7 +23,7 @@ def {{ .Rule.Name }}_impl(ctx):
ctx.file.template.path,
ctx.attr.name,
]
extra_protoc_files += [ctx.file.template]
extra_protoc_files.append(ctx.file.template)
# Execute with extracted attrs
return proto_compile(ctx, options, extra_protoc_args, extra_protoc_files)