OmniSharp / omnisharp-roslyn

OmniSharp server (HTTP, STDIO) based on Roslyn workspaces
MIT License
1.72k stars 417 forks source link

Query the language server #1878

Open Gankarloo opened 3 years ago

Gankarloo commented 3 years ago

Is it possible to query the language server for example the path to the current project file. I see in the lsp output that it correctly finds my csproj file

I have not found any documentation regarding the lsp, if there is one please do point it out.

david-driscoll commented 3 years ago

So lsp itself doesn't have that data available, the OmniSharp server does surface this information with some of our endpoints, which request calling the custom endpoints.

A reference list is, when running in lsp mode the handlers are all bound using o#/{method} https://github.com/OmniSharp/omnisharp-roslyn/blob/8e7eef87ad340664fcbc151f8d8742eed69410bc/src/OmniSharp.Abstractions/OmniSharpEndpoints.cs