fix(core): print error if there is an issue creating the sandbox during create (#5380)
This commit is contained in:
parent
60de1f123d
commit
fb0411ee8f
@ -476,10 +476,23 @@ function createSandbox(packageManager: string) {
|
|||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
execSync(`${packageManager} install --silent`, {
|
try {
|
||||||
cwd: tmpDir,
|
execSync(`${packageManager} install --silent`, {
|
||||||
stdio: [0, 1, 2],
|
cwd: tmpDir,
|
||||||
});
|
stdio: 'ignore',
|
||||||
|
});
|
||||||
|
} catch (_) {
|
||||||
|
// Install failed so run again without --silent
|
||||||
|
try {
|
||||||
|
execSync(`${packageManager} install`, {
|
||||||
|
cwd: tmpDir,
|
||||||
|
stdio: [0, 1, 2],
|
||||||
|
});
|
||||||
|
} catch (e) {
|
||||||
|
// This will probably fail so we exit with the same status
|
||||||
|
process.exit(e.status);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return tmpDir;
|
return tmpDir;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user