OpenAPITools / openapi-generator

OpenAPI Generator allows generation of API client libraries (SDK generation), server stubs, documentation and configuration automatically given an OpenAPI Spec (v2, v3)
https://openapi-generator.tech
Apache License 2.0
20.6k stars 6.29k forks source link

[REQ] Convert `debug` global properties to separate output options #18880

Open kriswuollett opened 4 weeks ago

kriswuollett commented 4 weeks ago

Is your feature request related to a problem? Please describe.

Cannot currently output debugging information as described in https://openapi-generator.tech/docs/debugging#templates separate from logs without also changing the logging configuration since the output stream is mixed, by default.

Describe the solution you'd like

Instead of running a command like:

openapi-generator generate -g go \
    -o out \
    -i petstore-minimal.yaml \
    --global-property debugModels,debugOperations

I should be able to run:

# also support debugSupportingFiles and debugOpenAPI the same way
openapi-generator generate -g go \
    -o out \
    -i petstore-minimal.yaml \
    --debug-models-out debug/models.json \
    --debug-operations-out debug/operations.json

Describe alternatives you've considered

None