build: 清理异常

pull/41/head
zjx0905 2023-04-11 15:40:46 +08:00
parent 05aa4955f4
commit 8aca3be4fc
1 changed files with 10 additions and 5 deletions

View File

@ -14,11 +14,16 @@ function main() {
exec('rimraf dist');
consola.info('Rollup');
exec(
`rollup -c ${
watch ? '-w' : ''
} --environment SOURCE_MAP:${sourceMap},DTS:${dts}`,
);
try {
exec(
`rollup -c ${
watch ? '-w' : ''
} --environment SOURCE_MAP:${sourceMap},DTS:${dts}`,
);
} catch {
consola.error('已退出');
process.exit();
}
console.info('\n');
}