mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-03-03 19:43:04 +08:00
[*] postinstall: Don't try to link cloud specs if pkgs don't exist
Summary: see title Test Plan: manual Reviewers: evan, spang, mark, halla Reviewed By: halla Differential Revision: https://phab.nylas.com/D4446
This commit is contained in:
parent
148fbfd936
commit
daf7f9ec6f
1 changed files with 9 additions and 4 deletions
|
@ -127,11 +127,16 @@ function linkJasmineConfigs() {
|
|||
console.log("\n---> Linking Jasmine configs");
|
||||
const linkToPackages = ['cloud-api', 'cloud-core', 'cloud-workers']
|
||||
const from = getJasmineConfigPath('isomorphic-core')
|
||||
|
||||
for (const packageName of linkToPackages) {
|
||||
const dir = getJasmineDir(packageName)
|
||||
if (!fs.existsSync(dir)) {
|
||||
fs.mkdirSync(dir)
|
||||
const packageDir = path.join('packages', packageName)
|
||||
if (!fs.existsSync(packageDir)) {
|
||||
console.log("\n---> No cloud packages to link. Moving on")
|
||||
return
|
||||
}
|
||||
|
||||
const jasmineDir = getJasmineDir(packageName)
|
||||
if (!fs.existsSync(jasmineDir)) {
|
||||
fs.mkdirSync(jasmineDir)
|
||||
}
|
||||
const to = getJasmineConfigPath(packageName)
|
||||
unlinkIfExistsSync(to)
|
||||
|
|
Loading…
Reference in a new issue