-
-
Notifications
You must be signed in to change notification settings - Fork 564
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
Allow setting protoc command via Meta #3633
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great! I left a few suggestions - nothing major though.
Looks great! One tiny last modification: it would probably be good to have a header comment on the "DefaultProtoc" constant so that it is clearly documented in the dsl package online docs. Thank you! |
Whoops, good catch. Thanks for the great feedback, especially pointing me to the |
Thank you for the great contribution! |
Fixes #3623
Adds a meta value
protoc:cmd
to override the command (and prefix args).If the meta value is provided for both the service and the API, the API will be used an API-wide default and the Service definition will be used as a Service-level override. This seems to make more sense than appending them together like we do with includes.
I wasn't sure if it made more sense to have
Meta("protoc:cmd")
(no values) do nothing or restore the defaultprotoc
if used as an override in the Service definition, so I made it error. Also considered not allowing it on the service definition to avoid the situation.Tested this with a private project as well.