-
-
Notifications
You must be signed in to change notification settings - Fork 83
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
Added reindex command #522
Conversation
Is there a reason not to use the LSP's Execute Command functionality? We can share known commands with server capabilities on initialize. https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#workspace_executeCommand |
My apologies: I see we are doing this. The code lens is just a convenient interface to trigger it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't test this until later, but made some comments for now.
apps/remote_control/lib/lexical/remote_control/commands/reindex.ex
Outdated
Show resolved
Hide resolved
my understanding is that the only two ways to use that functionality are code actions and code lenses. |
0e36eb9
to
9ba0325
Compare
Added a reindex code lens so we can rebuild indexes without resorting to manual operations. As we build the indexing infrastructure out, we'll likely need to rebuild the index a lot. Presently, this means restarting the server, which can take some time, so I thought i'd add a command to do it instead. I tried using code actions, but this was a bit fraught, so instead, I used a code lens on the project definition in your mix.exs file.
* Emit a more detailed reason for indexing failures * Added more unit tests for when code lenses should appear
Server originated requests now have improved ergonomics and support requests with no params
9ba0325
to
4ac5361
Compare
The code lens now disappears after it's been clicked, and reappears when indexing has completed.
4ac5361
to
a3bb0ef
Compare
Added a reindex code lens so we can rebuild indexes without resorting to manual operations.
As we build the indexing infrastructure out, we'll likely need to rebuild the index a lot. Presently, this means restarting the server, which can take some time, so I thought i'd add a command to do it instead. I tried using code actions, but this was a bit fraught, so instead, I used a code lens on the project definition in your mix.exs file.
Fixes #517