Error: ENOENT when generating schema from multiple .yaml
files from another directory
#1198
Closed
2 tasks done
Labels
Description
Error when generating schema from multiple
.yaml
files from another directory in the parent folder (see directory structure below).Thus, the yaml file is not in the same folder as where the
package.json
is (because we reuse it for generation of code of another language).The error I get is the following (note: I replaced the real directory with
$HOME
):openapi-typescript
6.2.8
v18.14.1
macOS 13.4.1
Reproduction
I have the following directory structure:
Directory structure:
And package.json looks like the following:
However, when I run
npx openapi-typescript ./../apis/views/**.yaml --output schemas/../../views/
, it works!But the
DetailView.ts
is created in theapi-contracts/apis/views
folder.I think the
outputFilePath
is mixed with theinputFilePath
, while it should not, incli.js
:Expected result
Generate the
DetailView.ts
file inapi-contracts/typescript-generation/schemas/views/
.Checklist
npx @redocly/cli@latest lint
)The text was updated successfully, but these errors were encountered: