Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GSoC] Language Server Protocol Plugin Support #659

Open
3 of 12 tasks
betterclever opened this issue May 16, 2018 · 5 comments
Open
3 of 12 tasks

[GSoC] Language Server Protocol Plugin Support #659

betterclever opened this issue May 16, 2018 · 5 comments
Labels

Comments

@betterclever
Copy link
Member

betterclever commented May 16, 2018

This is a roadmap of the the steps planned by me to add support for the Language Server Protocol (LSP) Plugin Support in the Xi Editor.

Roadmap

Will be refined over time

  • Get a basic plugin working which can access the document state.
  • Discover improvements needed in current Plugin API to enable a very simple LSP usecase i.e. JSON.
  • Get the JSON Plugin Working. The basic idea is to develop a crate which is abstraction over the plugin_lib, which JSON Plugin will use to communicate with the Editor. The validation error messages can be dumped to stderr to begin with.
  • Figure out a plan for the features in a specific order in the LSP Plugin including:
    • Status Information
    • Inline Error and Warning Display
    • Hover Definitions
    • Go to Definition
    • Intelligent Autocompletion
    • Highlight References
    • Refactoring Support
  • Figure out a test language (probably Rust?) to begin with to implement and test all
    features.

TODO: More refined steps after the 4th step.

Planning

The basic architecture currently planned (needs review) can be described by the following picture.

lsp-archtecture

Roadblocks / Open Questions.

  • Managing Workspaces. Who should manage the workspaces: Xi-Core or the Plugin itself?
@cmyr
Copy link
Member

cmyr commented May 16, 2018

@betterclever great, I think this is a good high-level overview.

For now, I think that 'workspaces' should be managed by the plugin (the last step, here) maybe with help from the LSP library. Essentially the plugin will know every file that gets opened, and it can go looking for Cargo.toml files (or other workspace markers) and use those to figure out which files are part of which 'workspaces'.

We should consider that a single LSP client plugin, in xi, might actually be running multiple LSP sessions, if multiple workspaces are open. (I think this is how it would work?).

@skyne98
Copy link

skyne98 commented Nov 30, 2018

@cmyr, hey, any progress? What is the state of LSP support in Xi? Thanks!

@jansol
Copy link
Collaborator

jansol commented Nov 30, 2018

Many (most?) bits have PRs that at least were in a relatively working state. However they got kind of stuck in a discussion of how these things should be communicated to the client... The annotations PR (#1010) is one step towards specifying that.

@cmyr
Copy link
Member

cmyr commented Dec 1, 2018

@skyne98 there was a bunch of exploratory work on this this summer, but the conclusion of that was that we should step back and work on incrementally adding support for the features that will enable LSP support in the future. The issue linked above is a first step there.

@ShalokShalom
Copy link

ShalokShalom commented May 5, 2019

Currently, the further development is stalled until this new plugin system is written: #845

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants