rules_swift
rules_swift copied to clipboard
Add generate_internal_visibility_from_proto_files feature
Fixes #961
Change
Create a new feature swift.generate_internal_visibility_from_proto_files which will set protoc's swift_opt Visibility from Public to Internal.
Test
- Create a valid rule for
swift_grpc_libraryorswift_proto_library- Verify the generated sources still have the "public" access modifier
- Add the
swift.generate_internal_visibility_from_proto_filesto thefeaturesattribute for the above rule- Verify the generated sources now omit access modifiers (implicitly
internal)
- Verify the generated sources now omit access modifiers (implicitly
Note
The ideal solution would be to make the Public setting opt-in for this feature, thereby mirroring default protoc Swift plugin behavior. Since rules_swift has always defaulted to public visibility this should instead remain the default.
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
View this failed invocation of the CLA check for more information.
For the most up to date status, view the checks section at the bottom of the pull request.