mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-21 00:50:13 +01:00
This commit is contained in:
parent
3c2ae5606d
commit
cdc8f4154d
1 changed files with 5 additions and 7 deletions
|
|
@ -384,8 +384,7 @@ const initKernel = (workspace, lang) => {
|
||||||
resolve(false)
|
resolve(false)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
// TODO
|
if (isDevEnv) {
|
||||||
if (!isDevEnv) {
|
|
||||||
writeLog('got kernel port [' + kernelPort + ']')
|
writeLog('got kernel port [' + kernelPort + ']')
|
||||||
} else {
|
} else {
|
||||||
const getAvailablePort = () => {
|
const getAvailablePort = () => {
|
||||||
|
|
@ -412,9 +411,9 @@ const initKernel = (workspace, lang) => {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const cmds = ['--port', kernelPort, '--wd', appDir]
|
const cmds = ['--port', kernelPort, '--wd', appDir]
|
||||||
// TODO if (isDevEnv) {
|
if (isDevEnv) {
|
||||||
// cmds.push('--mode', 'dev')
|
cmds.push('--mode', 'dev')
|
||||||
// }
|
}
|
||||||
if (workspace) {
|
if (workspace) {
|
||||||
cmds.push('--workspace', workspace)
|
cmds.push('--workspace', workspace)
|
||||||
cmds.push('--lang', lang)
|
cmds.push('--lang', lang)
|
||||||
|
|
@ -423,8 +422,7 @@ const initKernel = (workspace, lang) => {
|
||||||
' ')}]`
|
' ')}]`
|
||||||
writeLog(cmd)
|
writeLog(cmd)
|
||||||
let kernelProcessPid = ''
|
let kernelProcessPid = ''
|
||||||
// TODO
|
if (!isDevEnv) {
|
||||||
if (isDevEnv) {
|
|
||||||
const cp = require('child_process')
|
const cp = require('child_process')
|
||||||
const kernelProcess = cp.spawn(kernelPath,
|
const kernelProcess = cp.spawn(kernelPath,
|
||||||
cmds, {
|
cmds, {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue