Skip to content

Commit 2e2217a

Browse files
committed
Ensures output directory exists
1 parent 8fbbee7 commit 2e2217a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -501,6 +501,7 @@ class DiffDevProdCommand extends Command {
501501
const raw_html_diff = Diff2html.html(diff_output);
502502
const html_diff = createHtmlDiff({ title: root_domain, diff: raw_html_diff });
503503

504+
await fs.ensureDir(path.dirname(output_filename));
504505
await fs.writeFile(output_filename, html_diff);
505506
loud && this.log(chalk.green(`Written to ${chalk.blue(output_filename)}`));
506507
}

0 commit comments

Comments
 (0)