bazel-contrib / bazel-gazelle

Gazelle is a Bazel build file generator for Bazel projects. It natively supports Go and protobuf, and it may be extended to support new languages and custom rule sets.
Apache License 2.0
1.21k stars 381 forks source link

do not generate an empty rule if a go_proto_library was already gener… #1927

Closed davidbyttow closed 1 month ago

davidbyttow commented 2 months ago

What type of PR is this?

Bug fix

What package or component does this PR mostly affect?

language/go

What does this PR do? Why is it needed?

Prevents overwriting of a generated go_proto_library in the case where the package name matches the proto file name. See issue for more details.

Which issues(s) does this PR fix? Fixes #1926

Other notes for review Unclear exactly how to write a test for it, but did local testing at least.

davidbyttow commented 1 month ago

added tests