Support other extensions for published image#170
Support other extensions for published image#170andrewparmet merged 13 commits intobufbuild:mainfrom
Conversation
|
Two initial thoughts: First, I see a list of file names that Buf recognizes in the docs:
Do you know if the current implementation of Second, I'm thinking about the plugin API. Previously the contract was:
This change introduces a new contract:
On the whole both contracts are limiting if users want to use that file for purposes that aren't built-in to the plugin since we offer no way to grab the built image file without building a file path yourself. Given that the plugin exposes the file via the constant today, the README should be updated to call out the Stepping back I think it's a good feature to be able to produce an image in any supported format. This leaves a few action items before we can move forward:
Lots to think about. Thanks for taking on this new feature! |
|
@andrewparmet Firstly, I'm going to implement a integration test to check if Secondly, regarding the new plugin API, I think it's fine just to be able to configure the image extension. I agree with your opinion that we should let users choose their desired format and compression pair. I think we should control users to choose the pair from this list. Lastly, I don't think we should unify three options: |
|
For this PR I think it's ok to leave the configuration APIs as they are, and I'll tweak them for some coherence afterwards. Yes, that list is more thorough than what I saw. May I ask what your use case is? I'm wondering if this plugin can more directly support it. |
|
My team is using Armeria as a grpc framework, which takes a descriptor file for its doc service. |
|
I added some tests to check if It seems
Could you please review the code again? |
…into support-other-format-for-image
|
Hi @andrewparmet. If there's anything I can do to help move it along, just let me know. I'm all ears for any feedback you might have. |
andrewparmet
left a comment
There was a problem hiding this comment.
Sorry for the delay. A few light questions.
|
@andrewparmet I changed the code to separate the extension option into a format and compression method option. |
|
Released in 0.9.0 |
This PR adds new option that allows users to specify an image filename published by
bufBuild.Users can specify other formats than
json.