-
Notifications
You must be signed in to change notification settings - Fork 526
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
Expose generation methods for buf #598
Conversation
5cfb922
to
cfed201
Compare
This has now been updated to an even smaller, minimum viable set of changes to support an external plugin executable. I've create that executable now at https://github.com/neoeinstein/protoc-gen-prost. Presuming this looks good, I'll be in a position to push up a |
cfed201
to
b2e046a
Compare
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 is a good start! Left a question but I think we are moving in the right direction.
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.
Almost there! Just two more comments then I think we are good to merge.
I believe that this is ready for a new review. |
This revives PR #313. With the advent of v1.0 of buf.build, the ecosystem for generating polyglot code from protobuf heavily favors the plugin model. It very easily slots into the
buf generate
model. This revival creates a distinctprotoc-gen-prost
crate to host the binary, rather than the prior method of putting the binary in theprost-build
crate. This makes installation usingcargo install protoc-gen-prost
more convenient.In my opinion, Prost would benefit from integrating into this model, so I wanted to revive the old protoc plugin. Even with this very basic PR (which doesn't handle options), I have confirmed that puting the binary onto the
PATH
and runningbuf generate
results in precisely the Rust code I would expect over a somewhat complicated hierarchy of protobuf files.