Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support proto_compiled_sources with ts_project #378

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

pcj
Copy link
Member

@pcj pcj commented Jul 16, 2024

In certain contexts, we want to be able to use proto_compiled_sources with ts_project.

ts_project has the behavior that it will copy_to_bin all files named in srcs that are source files (starlark File API file.is_source).

This presents a problem because if we have a proto_compile rule in the same package as a ts_project rule, they will attempt to produce the same (conflicting) file in the output tree.

This PR introduces attributes to the proto_compile rule that will (1) optionally suppress returning a DefaultInfo provider as well as (2) ability to rename the final output files to have a suffix (so as not to conflict with ones ts_project wants to produce).

The proto_compiled_sources macro has been refactored to support these attributes and use case above.

@pcj pcj changed the title proto_compile: support Support proto_compiled_sources with ts_project Jul 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant