meetup / rules_openapi

🍃 bazel rules for generating code from openapi specifications
MIT License
52 stars 25 forks source link

openapi: Allow multiple codegen versions in the same build #16

Closed philipl closed 5 years ago

philipl commented 5 years ago

We've got a requirement to be able to run codegen with two different versions of the cli, and that's currently not possible because it's only possible to declare one cli dependency at a time.

My approach here is to allow the Label of a declared cli jar to be customisable, and then to allow the rule to be passed a custom Label.

Technically, only the second change is needed as I could declare the second jar on my own, but it seems reasonable to allow the Label customisation.

softprops commented 5 years ago

wow. neat approach @philipl!