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

Add support of the official workspaceFolders #1245

Open
fortime opened this issue Nov 6, 2019 · 1 comment
Open

Add support of the official workspaceFolders #1245

fortime opened this issue Nov 6, 2019 · 1 comment

Comments

@fortime
Copy link

fortime commented Nov 6, 2019

Currently, JDT Language Server uses initializationOptions to pass workspaceFolders.
https://github.com/eclipse/eclipse.jdt.ls/blob/1dfdeeafb9d0dd7c16d915763a30088dfa3a721e/org.eclipse.jdt.ls.core/src/org/eclipse/jdt/ls/core/internal/handlers/InitHandler.java#L93

Since 3.6, lsp has added a parameter for passing workspaceFolders.
https://github.com/eclipse/lsp4j/blob/2a3db10fe9719f3869a715c58fd683bd493dfdeb/org.eclipse.lsp4j/src/main/xtend-gen/org/eclipse/lsp4j/InitializeParams.java#L73-L81

I use ycmd, it uses the official parameter.
Please add support for it. Maybe I can create a PR. But, I am not clear if I should keep the old way.

@joaotavora
Copy link

In the interim, something that is probably easiest to implement is to allow the code that @fortime points to to accept not only a JSON vector of strings, but also a JSON vector of objects containing "uri" and "name" as keys. Then at least it will be closer to what the LSP protocol specifies and allow clients to more easily adapt (like here joaotavora/eglot#909 (reply in thread))

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

No branches or pull requests

3 participants