ballerina-platform / lsp4intellij

This language client library provides language server protocol support for IntelliJ IDEA and other Jetbrains IDEs.
Apache License 2.0
428 stars 104 forks source link

Opening up the ServerDefinition to all languages #339

Open payne911 opened 9 months ago

payne911 commented 9 months ago

It would be great if we wouldn't have to exhaustively declare all supported file types in the ServerDefinition.

nixel2007 commented 9 months ago

You can add a property in your plugin and make it configurable by end user

payne911 commented 9 months ago

But then the end user would themselves have to list every single individual extension they want to support ?

nixel2007 commented 9 months ago

Yes. Also there are file watches created for files with this extensions so plugin can handle file modifications and send events to the language server. Why do you need to register all extensions? Is your language server a generic one, which eally can handle any file, and not tied to any programming language?

payne911 commented 9 months ago

Is your language server a generic one, which eally can handle any file, and not tied to any programming language?

No, but it's annoying to have to maintain a list of the 50+ extensions we support. The extensions we don't support are somewhat rare and usually wouldn't exist within our company's repository so it's safe to assume that it would indeed handle pretty much any file opened.

... but yes, obviously the better thing to do is indeed to list each extension.