chore(scripts): coding style
This commit is contained in:
parent
bf3f9b4ac2
commit
299fdc19d6
@ -10,6 +10,6 @@ module.exports = {
|
|||||||
'node/no-extraneous-require': 'error',
|
'node/no-extraneous-require': 'error',
|
||||||
'node/no-missing-import': 'error',
|
'node/no-missing-import': 'error',
|
||||||
'node/no-missing-require': 'error',
|
'node/no-missing-require': 'error',
|
||||||
'prefer-const': 'error'
|
'prefer-const': 'error',
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@ require('exec-promise')(([ command, ...args ]) =>
|
|||||||
console.log('*', name)
|
console.log('*', name)
|
||||||
return fromEvent(spawn(command, args, {
|
return fromEvent(spawn(command, args, {
|
||||||
cwd: dir,
|
cwd: dir,
|
||||||
stdio: 'inherit'
|
stdio: 'inherit',
|
||||||
}), 'exit').then(code => {
|
}), 'exit').then(code => {
|
||||||
if (code !== 0) {
|
if (code !== 0) {
|
||||||
throw code
|
throw code
|
||||||
|
@ -20,10 +20,10 @@ require('exec-promise')(([ script ]) =>
|
|||||||
const spawnOpts = {
|
const spawnOpts = {
|
||||||
cwd: dir,
|
cwd: dir,
|
||||||
env: Object.assign({}, env, {
|
env: Object.assign({}, env, {
|
||||||
PATH: `${dir}/node_modules/.bin${delimiter}${env.PATH}`
|
PATH: `${dir}/node_modules/.bin${delimiter}${env.PATH}`,
|
||||||
}),
|
}),
|
||||||
shell: true,
|
shell: true,
|
||||||
stdio: 'inherit'
|
stdio: 'inherit',
|
||||||
}
|
}
|
||||||
return forEach.call(
|
return forEach.call(
|
||||||
[ `pre${script}`, script, `post${script}` ],
|
[ `pre${script}`, script, `post${script}` ],
|
||||||
|
Loading…
Reference in New Issue
Block a user