|
@@ -68,7 +68,8 @@ const copyToOut = async (file, config) => {
|
|
console.log(`Copying ${file} to ${outputPath}`);
|
|
console.log(`Copying ${file} to ${outputPath}`);
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
- await fs.mkdir(outputPath.replace(/\/[^/]+$/, ""), { recursive: true });
|
|
|
|
|
|
+ let dirNameRegex = new RegExp("\\" + path.sep + "([^\\" + path.sep + "]+)$");
|
|
|
|
+ await fs.mkdir(outputPath.replace(dirNameRegex, ""), { recursive: true });
|
|
await fs.copyFile(file, outputPath);
|
|
await fs.copyFile(file, outputPath);
|
|
};
|
|
};
|
|
|
|
|
|
@@ -105,4 +106,4 @@ const medusaTransform = async (file) => {
|
|
// Compile all files
|
|
// Compile all files
|
|
await Promise.all(files.map(async (file) => medusaTransform(file)));
|
|
await Promise.all(files.map(async (file) => medusaTransform(file)));
|
|
|
|
|
|
-console.log(`Compiled all files in ${Date.now() - started}ms`);
|
|
|
|
|
|
+console.log(`Compiled all files in ${Date.now() - started}ms`);
|