2017-04-30 22:01:12 +00:00
|
|
|
#!/usr/bin/env node
|
|
|
|
const sh = require('shelljs')
|
|
|
|
const path = require('path')
|
|
|
|
const vars = require('./vars')
|
2017-06-09 22:29:16 +00:00
|
|
|
const log = require('npmlog')
|
2017-04-30 22:01:12 +00:00
|
|
|
|
2021-07-10 15:51:37 +00:00
|
|
|
const localBinPath = path.resolve(__dirname, '../node_modules/.bin')
|
|
|
|
const npx = `${localBinPath}/npx`
|
|
|
|
|
|
|
|
log.info('patch')
|
|
|
|
sh.exec(`${npx} patch-package`)
|
2017-11-28 05:19:38 +00:00
|
|
|
|
2017-06-09 22:29:16 +00:00
|
|
|
log.info('deps', 'app')
|
2017-04-30 22:01:12 +00:00
|
|
|
|
2017-06-20 21:28:58 +00:00
|
|
|
sh.cd('app')
|
2020-12-23 20:45:47 +00:00
|
|
|
sh.exec(`${npx} yarn install --force`)
|
2017-06-20 21:28:58 +00:00
|
|
|
sh.cd('..')
|
|
|
|
|
2021-06-19 20:01:35 +00:00
|
|
|
sh.cd('web')
|
|
|
|
sh.exec(`${npx} yarn install --force`)
|
|
|
|
sh.cd('..')
|
|
|
|
|
2017-04-30 22:01:12 +00:00
|
|
|
vars.builtinPlugins.forEach(plugin => {
|
2021-07-10 15:51:37 +00:00
|
|
|
log.info('deps', plugin)
|
|
|
|
sh.cd(plugin)
|
|
|
|
sh.exec(`${npx} yarn install --force`)
|
|
|
|
sh.cd('..')
|
2017-04-30 22:01:12 +00:00
|
|
|
})
|
2018-03-23 16:15:11 +00:00
|
|
|
|
|
|
|
if (['darwin', 'linux'].includes(process.platform)) {
|
2021-07-10 15:51:37 +00:00
|
|
|
sh.cd('node_modules')
|
|
|
|
for (let x of vars.builtinPlugins) {
|
|
|
|
sh.ln('-fs', '../' + x, x)
|
|
|
|
}
|
|
|
|
sh.cd('..')
|
2018-03-23 16:15:11 +00:00
|
|
|
}
|