Skip to content

Commit d9f520a

Browse files
committed
Merge branch 'master' of https://github.com/alanz/vscode-hie-server into snippets
2 parents 5bd846d + 24a9021 commit d9f520a

File tree

4 files changed

+13
-2
lines changed

4 files changed

+13
-2
lines changed

Changelog.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
### 0.0.23
2+
3+
* Fix multi-process issue, where vscode would launch multiple hie instances.
4+
By @kfigiela
5+
16
### 0.0.22
27

38
* Add configuration option to enable liquid haskell processing. This

hie-vscode.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
export HIE_SERVER_PATH=`which hie`
44
export HIE_WRAPPER_PATH=`which hie-wrapper`
55

6-
if [ "X" = "X$HIE_WRAPPER_PATH" ]; then
6+
if [ ! "X" = "X$HIE_WRAPPER_PATH" ]; then
77
hie-wrapper --lsp $@
88
elif [ "X" = "X$HIE_SERVER_PATH" ]; then
99
echo "Content-Length: 100\r\n\r"

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "vscode-hie-server",
33
"displayName": "Haskell Language Server",
44
"description": "Language Server Protocol for Haskell via HIE",
5-
"version": "0.0.22",
5+
"version": "0.0.23",
66
"license": "MIT",
77
"publisher": "alanz",
88
"engines": {

src/extension.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,12 @@ function activateHieNoCheck(context: ExtensionContext, folder: WorkspaceFolder,
210210
hieCommandsRegistered = true;
211211
}
212212

213+
// If the client already has an LSP server, then don't start a new one.
214+
// We check this again, as there may be multiple parallel requests.
215+
if (clients.has(folder.uri.toString())) {
216+
return;
217+
}
218+
213219
// Finally start the client and add it to the list of clients.
214220
langClient.start();
215221
clients.set(folder.uri.toString(), langClient);

0 commit comments

Comments
 (0)