Merge pull request #19762 from storybookjs/valentin/fix-windows-prep-build

Fix prepare script on Windows machines
This commit is contained in:
Kasper Peulen 2022-11-06 16:50:22 +01:00 committed by GitHub
commit d6d7a500a2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -41,7 +41,7 @@ const run = async ({ cwd, flags }: { cwd: string; flags: string[] }) => {
const pathName = join(process.cwd(), dir.replace('./src', 'dist'), `${entryName}.d.ts`);
const srcName = join(process.cwd(), file);
const rel = relative(dirname(pathName), dirname(srcName));
const rel = relative(dirname(pathName), dirname(srcName)).split(path.sep).join(path.posix.sep);
await fs.ensureFile(pathName);
await fs.writeFile(