Skip to content

Commit 649d44a

Browse files
committed
handle nested paths
Quick fix to handle path like: `dir1/dir2/file.js`
1 parent 4eeffd0 commit 649d44a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ ConfigReplace.prototype.processFile = function(config, filePath) {
9595

9696
ConfigReplace.prototype.writeFile = function(destPath, contents) {
9797
if (!fs.existsSync(path.dirname(destPath))) {
98-
fs.mkdirSync(path.dirname(destPath));
98+
fs.mkdirpSync(path.dirname(destPath));
9999
}
100100

101101
fs.writeFileSync(destPath, contents, { encoding: 'utf8' });

0 commit comments

Comments
 (0)