Skip to content

Commit 83ffcd7

Browse files
fix(migration): fix build
1 parent df51c99 commit 83ffcd7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

migrate/migrate-bot.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -418,10 +418,10 @@ async function main() {
418418
await writeMDXFile(filePath, mdx, title);
419419

420420
console.log(` 尝试构建...`);
421-
const res = spawnSync(`npm`, ["run", "build"], { stdio: "inherit" });
421+
const res = spawnSync(`npm`, ["run", "build"], { stdio: "inherit", shell: true });
422422
if (res.status !== 0) {
423423
throw new Error(
424-
"构建失败,可能生成的MDX有问题:" + res.stderr?.toString() + res.stdout?.toString() + " exit code " + res.status
424+
"构建失败,可能生成的MDX有问题:" + res.stderr?.toString() + res.stdout?.toString() + res.error?.toString() + " exit code " + res.status
425425
);
426426
}
427427

0 commit comments

Comments
 (0)