Skip to content
代码片段 群组 项目
提交 19f90022 编辑于 作者: Timotej Ecimovic's avatar Timotej Ecimovic
浏览文件

Allow zap-start to choose electron vs node.

上级 be2549fd
No related branches found
No related tags found
无相关合并请求
......@@ -27,8 +27,19 @@ scriptUtil
.then(() => scriptUtil.rebuildSpaIfNeeded())
.then((ctx) => {
let cmdArgs = ['src-electron/main-process/electron-main.js']
cmdArgs.push(...process.argv.slice(2))
return scriptUtil.executeCmd(ctx, 'electron', cmdArgs)
args = process.argv.slice(2)
let executor = null
if (
args[0] == 'generate' ||
args[0] == 'selfCheck' ||
args[0] == 'analyze' ||
args[0] == 'convert' ||
args[0] == 'server'
)
executor = 'node'
else executor = 'electron'
cmdArgs.push(...args)
return scriptUtil.executeCmd(ctx, executor, cmdArgs)
})
.then(() => {
let endTime = process.hrtime(startTime)
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册