mirror of https://github.com/coder/code-server.git
Fix import of server-main.js from main
Neglected to update this import when fixing the other.
This commit is contained in:
parent
fc6064dcd3
commit
7c298653f1
|
@ -49,7 +49,9 @@ export interface OpenCommandPipeArgs {
|
||||||
export const runCodeCli = async (args: DefaultedArgs): Promise<void> => {
|
export const runCodeCli = async (args: DefaultedArgs): Promise<void> => {
|
||||||
logger.debug("Running Code CLI")
|
logger.debug("Running Code CLI")
|
||||||
try {
|
try {
|
||||||
const mod = require(path.join(vsRootPath, "out/server-main")) as VSCodeModule
|
// See vscode.loadVSCode for more on this jank.
|
||||||
|
const modPath = path.join(vsRootPath, "out/server-main.js")
|
||||||
|
const mod = (await eval(`import("${modPath}")`)) as VSCodeModule
|
||||||
const serverModule = await mod.loadCodeWithNls()
|
const serverModule = await mod.loadCodeWithNls()
|
||||||
await serverModule.spawnCli(await toCodeArgs(args))
|
await serverModule.spawnCli(await toCodeArgs(args))
|
||||||
// Rather than have the caller handle errors and exit, spawnCli will exit
|
// Rather than have the caller handle errors and exit, spawnCli will exit
|
||||||
|
|
Loading…
Reference in New Issue