diff options
author | Laurențiu Nicola <[email protected]> | 2019-12-08 19:08:46 +0000 |
---|---|---|
committer | Laurențiu Nicola <[email protected]> | 2019-12-08 19:14:18 +0000 |
commit | ee2bc73d2a8bb5479019609b495c65d1d6132d9b (patch) | |
tree | e479ccc45e97f218b8d7276bf70693506449867a /editors | |
parent | 6b1c2ee168151db07e42403c37106491ff45c5e6 (diff) |
Code: don't check for ra_lsp_server on Windows
Diffstat (limited to 'editors')
-rw-r--r-- | editors/code/src/server.ts | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/editors/code/src/server.ts b/editors/code/src/server.ts index e717ab294..b346c0828 100644 --- a/editors/code/src/server.ts +++ b/editors/code/src/server.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import { lookpath } from 'lookpath'; | 1 | import { lookpath } from 'lookpath'; |
2 | import { homedir } from 'os'; | 2 | import { homedir, platform } from 'os'; |
3 | import * as lc from 'vscode-languageclient'; | 3 | import * as lc from 'vscode-languageclient'; |
4 | 4 | ||
5 | import { window, workspace } from 'vscode'; | 5 | import { window, workspace } from 'vscode'; |
@@ -29,10 +29,14 @@ export class Server { | |||
29 | } | 29 | } |
30 | 30 | ||
31 | const command = expandPathResolving(this.config.raLspServerPath); | 31 | const command = expandPathResolving(this.config.raLspServerPath); |
32 | if (!(await lookpath(command))) { | 32 | // FIXME: remove check when the following issue is fixed: |
33 | throw new Error( | 33 | // https://github.com/otiai10/lookpath/issues/4 |
34 | `Cannot find rust-analyzer server \`${command}\` in PATH.` | 34 | if (platform() !== 'win32') { |
35 | ); | 35 | if (!(await lookpath(command))) { |
36 | throw new Error( | ||
37 | `Cannot find rust-analyzer server \`${command}\` in PATH.` | ||
38 | ); | ||
39 | } | ||
36 | } | 40 | } |
37 | const run: lc.Executable = { | 41 | const run: lc.Executable = { |
38 | command, | 42 | command, |