Skip to content

Commit

Permalink
Merge pull request #113 from docsbydoxdox/hotfix/mkdir-recursively
Browse files Browse the repository at this point in the history
[hotfix] Make directory before rendering output.
  • Loading branch information
neogeek authored Feb 2, 2022
2 parents 2900306 + 14ad8bf commit f9a98d8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/doxdox-cli/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,8 @@ const overridePackage = args.flags['-p'] || args.flags['--package'];
});

if (overrideOutput) {
await fs.mkdir(dirname(overrideOutput), { recursive: true });

await fs.writeFile(overrideOutput, output);
} else {
process.stdout.write(output);
Expand Down

0 comments on commit f9a98d8

Please sign in to comment.