Generating client with multiple files as input
uc-asa opened this issue · 2 comments
uc-asa commented
Multiple file input and input with ref in YAML doesn't support.
minh-thai commented
Hi @uc-asa , I found a solution as follows:
1/ Create openapitools.json with the following configuration
{
"$schema": "node_modules/@openapitools/openapi-generator-cli/config.schema.json",
"spaces": 2,
"generator-cli": {
"version": "5.3.0",
"generators": {
"publicApi": { // This name is arbitrary string
"generatorName": "typescript-angular",
"glob": "./openapi_spec/publicApi.yaml",
"output": "./src/app/openapi_codegen/publicApi",
},
"privateApi": { // This name is arbitrary string
"generatorName": "typescript-angular",
"glob": "./openapi_spec/privateApi.yaml",
"output": "./src/app/openapi_codegen/privateApi",
},
... // add configurations for other spec files as expected
}
}
}
2/ Run the command: openapi-generator-cli generate --generator-key publicApi privateApi
bodograumann commented
Turning off useDocker
seems to work for us. Unfortunately this brings other problems with it.