Skip to content
This repository has been archived by the owner on Apr 1, 2020. It is now read-only.

Commit

Permalink
Fix #420 - C# LSP plugin issues in distributed builds (#421)
Browse files Browse the repository at this point in the history
* Don't use hardcoded node variable

* Use the exec path

* Add quotes in paths
  • Loading branch information
extr0py authored Apr 30, 2017
1 parent c06101c commit c18fb1f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion browser/src/Plugins/Api/LanguageClient/LanguageClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export class LanguageClient {
public start(initializationParams: LanguageClientInitializationParams): Thenable<any> {

// TODO: Pursue alternate connection mechanisms besides stdio - maybe Node IPC?
this._process = exec(this._startCommand, { maxBuffer: 500 * 1024 * 1024 }, (err) => {
this._process = exec(`"${process.execPath}" "${this._startCommand}"`, { maxBuffer: 500 * 1024 * 1024, env: { ELECTRON_RUN_AS_NODE: 1 } }, (err) => {
if (err) {
console.error(err)
alert(err)
Expand Down
2 changes: 1 addition & 1 deletion vim/core/oni-plugin-csharp/lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const activate = (Oni) => {

const omniSharpLangServerPath = path.join(__dirname, "..", "..", "..", "..", "node_modules", "omnisharp-client", "languageserver", "server.js")

const execCommand = `node "${omniSharpLangServerPath}"`
const execCommand = `${omniSharpLangServerPath}`

const client = Oni.createLanguageClient(execCommand, (filePath) => {
return getRootProjectFileAsync(path.dirname(filePath))
Expand Down

0 comments on commit c18fb1f

Please sign in to comment.