Skip to content
This repository was archived by the owner on Mar 19, 2024. It is now read-only.

Commit 270fec3

Browse files
committed
Update to atom-languageclient 0.8
Remove Rls stderr logging code, upstreamed in atom/atom-languageclient#158
1 parent 15b8f31 commit 270fec3

File tree

3 files changed

+14
-26
lines changed

3 files changed

+14
-26
lines changed

lib/index.js

Lines changed: 4 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -197,24 +197,6 @@ function serverEnv(toolchain) {
197197
return env
198198
}
199199

200-
/**
201-
* Logs stderr if `core.debugLSP` is enabled
202-
* TODO should be handled upstream, see https://github.com/atom/atom-languageclient/issues/157
203-
* @param {process} process
204-
* @return {process}
205-
*/
206-
function logStdErr(process) {
207-
if (atom.config.get('core.debugLSP')) {
208-
process.stderr.on('data', chunk => {
209-
chunk.toString()
210-
.split('\n')
211-
.filter(l => l)
212-
.forEach(line => console.warn('Rls-stderr', line))
213-
})
214-
}
215-
return process
216-
}
217-
218200
/**
219201
* Check for and install Rls
220202
* @param [busySignalService]
@@ -420,18 +402,18 @@ class RustLanguageClient extends AutoLanguageClient {
420402
atom.notifications.addInfo(`Using rls command \`${cmdOverride}\``)
421403
this._warnedAboutRlsCommandOverride = true
422404
}
423-
return logStdErr(cp.spawn(cmdOverride, {
405+
return cp.spawn(cmdOverride, {
424406
env: serverEnv(),
425407
shell: true
426-
}))
408+
})
427409
}
428410

429411
return checkToolchain(this.busySignalService)
430412
.then(toolchain => checkRls(this.busySignalService).then(() => toolchain))
431413
.then(toolchain => {
432-
return logStdErr(cp.spawn("rustup", ["run", configToolchain(), "rls"], {
414+
return cp.spawn("rustup", ["run", configToolchain(), "rls"], {
433415
env: serverEnv(toolchain)
434-
}))
416+
})
435417
})
436418
}
437419
}

package-lock.json

Lines changed: 9 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"atom": ">=1.21.0"
1919
},
2020
"dependencies": {
21-
"atom-languageclient": "^0.7.3",
21+
"atom-languageclient": "^0.8.0",
2222
"atom-package-deps": "^4.6.1",
2323
"toml": "^2.3.3",
2424
"underscore-plus": "^1.6.6"

0 commit comments

Comments
 (0)