aboutsummaryrefslogtreecommitdiff
path: root/editors/code/src/client.ts
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-05-26 21:58:07 +0100
committerGitHub <[email protected]>2021-05-26 21:58:07 +0100
commitb4015b6aaa0dd80f5c85c7ed03e83d0d16042264 (patch)
tree6e423f24d05092250af44cacf1cb1b881d471492 /editors/code/src/client.ts
parent666fc1cec10a41f88db56dfb339785eb1e7dd521 (diff)
parenta05163db1429bfb8cf30dbea4b1aa86a24258d49 (diff)
Merge #8995
8995: fix: Create tasks for all workspaces r=matklad a=SomeoneToIgnore Follow-up of https://github.com/rust-analyzer/rust-analyzer/pull/8955#discussion_r637897170 Before: <img width="593" alt="image" src="https://user-images.githubusercontent.com/2690773/119575267-712b5300-bdbf-11eb-833c-f688f7a7dd0f.png"> After: <img width="643" alt="image" src="https://user-images.githubusercontent.com/2690773/119575273-74264380-bdbf-11eb-8283-a78bbcb7346e.png"> This is the first time I've used multiple workspaces feature in VSCode, but so far looks like * opening detached files works * run and debug lens work * Rust Analyzer: Run action works * run task works and now shows tasks for all workspaces * there are no platform-specific changes involved Co-authored-by: Kirill Bulatov <[email protected]>
Diffstat (limited to 'editors/code/src/client.ts')
-rw-r--r--editors/code/src/client.ts7
1 files changed, 1 insertions, 6 deletions
diff --git a/editors/code/src/client.ts b/editors/code/src/client.ts
index 69dbe2535..f13ae07e1 100644
--- a/editors/code/src/client.ts
+++ b/editors/code/src/client.ts
@@ -32,14 +32,9 @@ export function createClient(serverPath: string, workspace: Workspace, extraEnv:
32 const newEnv = Object.assign({}, process.env); 32 const newEnv = Object.assign({}, process.env);
33 Object.assign(newEnv, extraEnv); 33 Object.assign(newEnv, extraEnv);
34 34
35 let cwd = undefined;
36 if (workspace.kind === "Workspace Folder") {
37 cwd = workspace.folder.fsPath;
38 };
39
40 const run: lc.Executable = { 35 const run: lc.Executable = {
41 command: serverPath, 36 command: serverPath,
42 options: { cwd, env: newEnv }, 37 options: { env: newEnv },
43 }; 38 };
44 const serverOptions: lc.ServerOptions = { 39 const serverOptions: lc.ServerOptions = {
45 run, 40 run,