Re: [code] [textadept] New Language Server Protocol client module

From: Chris Emerson <c-ta.att.mail.nosreme.org>
Date: Sun, 14 Oct 2018 09:51:47 +0100

Hi Mitchell,

On Sat, Oct 13, 2018 at 11:26:12PM +0100, Chris Emerson wrote:
> I've made a few changes locally to the lsp module (sending RLS configuration,
> sending didSave notifications, tweaking diagnostics); I'll try to untangle
> the generally useful changes from my personal tweaks and send the useful ones
> in case you want to include them.

I've attached my current diff to your LSP module. This works for me on Linux
with the RLS - at least for diagnostics (I haven't yet looked into other
actions as it means thinking of key bindings. :-) ) I'm sure you won't want
all of them but I've included them for completeness!

The changes are:
* Bug fix: I still need to remove the "+ 1" in the call to handle:stdout.
* I added a `notif_handlers` table for registering user handlers for notifications.
I use this to handle "window/progress" messages from RLS.
* I send a "workspace/didChangeConfiguration" notification just after
initialization so that I can configure the RLS; it's hard coded so it should
probably really come from M.settings.
* I added a "didSave" notification; I have RLS configured to run a build when
saving.
* I removed the check which disables diagnostics near the cursor, since I want
them to show. I would guess you don't want that change. :-)

Cheers,

Chris

-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Sun 14 Oct 2018 - 04:51:47 EDT

This archive was generated by hypermail 2.2.0 : Sun 14 Oct 2018 - 06:32:00 EDT