From e2bc273c2190d7815c18c905675aa8f1fcf03ac1 Mon Sep 17 00:00:00 2001 From: "un.def" Date: Sat, 20 Jun 2020 14:53:33 +0300 Subject: [PATCH] Pass PATH env variable to server process Fixes #83 --- src/extension.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/extension.ts b/src/extension.ts index 96f780d..1074445 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -19,14 +19,20 @@ export function deactivate() { function startLanguageServer(context: vscode.ExtensionContext) { const serverModule = path.join(__dirname, '../server', 'main.js'); + const env = { + PATH: process.env.PATH + }; + const debugOptions = { execArgv: ['--nolazy', '--inspect=6009'], env: { + ...env, NODE_ENV: 'development' } }; const runOptions = { env: { + ...env, NODE_ENV: 'production' } };