Skip to content

Affect the Visibility for Swift Structs Generated from Protobuf #97

Answered by aaliddell
cgrindel asked this question in Q&A
Discussion options

You must be logged in to vote

There isn't presently a simple way of adding options on a per-target basis, due to the way aspects work in Bazel. You can add the options on a per-plugin basis, but this would require you to make your own copy of the plugin, which is a pain. The relevant issue is #54

I'm going to add another issue so we can track this for swift. Since this is only one option, it may be viable to work around the aspect limitation since we can enumerate the values.

Another option would be just to make the public visibility the default option for Swift, but that may have other implications. This is what rules_swift does: https://github.com/bazelbuild/rules_swift/blob/ca8fe5b39c273d1368723ec7e88470365c173687/…

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@aaliddell
Comment options

@cgrindel
Comment options

@aaliddell
Comment options

@cgrindel
Comment options

@aaliddell
Comment options

Answer selected by aaliddell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants