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

Add validate --recommend option to maven and gradle plugin options. #335

Closed
jimschubert opened this issue Jun 17, 2018 · 1 comment · Fixed by #5183
Closed

Add validate --recommend option to maven and gradle plugin options. #335

jimschubert opened this issue Jun 17, 2018 · 1 comment · Fixed by #5183

Comments

@jimschubert
Copy link
Member

Description

In #292, I implemented a --recommend option for the CLI's validate command. We'll want to add a similar option to the Maven and Gradle plugins.

I'm thinking that we could create a validator result object (e.g. ValidationSummary, with properties exposing a set of errors and a set of warnings) and a validator utility (e.g. SpecificationValidator), in which we encapsulate the logic for returning errors/warnings. The CLI command (and probably Maven and Gradle plugins) output a stringified result of errors and warnings, which would be a static utility method on the validator utility type. This would remove any inconsistencies between the tools and would allow other tools (like my IntelliJ plugin) consider "errors" the same as we consider them in openapi-generator; right now it's the same as swagger-parser, but this may not always be the case.

openapi-generator version

3.0.2+

Related issues/PRs
@jimschubert
Copy link
Member Author

This will have to come after #4979, so the validation work can be shared between the CLI and the plugins.

nilskuhn pushed a commit to nilskuhn/openapi-generator that referenced this issue Apr 6, 2023
feat(custom generators): added '--custom-generator' parameter fixes OpenAPITools#237
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant