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

Q LSP: expose actions as "code actions" #802

Open
justinmk3 opened this issue Feb 25, 2025 · 0 comments
Open

Q LSP: expose actions as "code actions" #802

justinmk3 opened this issue Feb 25, 2025 · 0 comments
Labels
tracked [Maintainer-Only] Issue is acknowledged and tracked by the team

Comments

@justinmk3
Copy link
Contributor

justinmk3 commented Feb 25, 2025

Problem

Q clients commonly provide features like Explain, Optimize, etc., which require very little UI (they send a canned query about code, and return chat responses). But even though the UI is simple, each Q LSP consumer must build this explicitly.

Image

Proposal

Expose code actions for basic features such as Explain, Optimize, etc.

This needs more thought, but at least initially these actions could easily be provided:

  • Explain: sends an "explain this code..." query and shows the response in a 'window/showMessage' event.
  • Optimize: sends an "optimize this code..." query and shows the response in a 'window/showMessage' event.
  • Use window/showMessageRequest to prompt user to select choices from a menu. ref
  • ...others?

This gives an "instant UI" for any LSP client that supports LSP code actions, without any explicit integration with Q LSP.

Related

@volodkevych volodkevych added the tracked [Maintainer-Only] Issue is acknowledged and tracked by the team label Mar 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tracked [Maintainer-Only] Issue is acknowledged and tracked by the team
Projects
None yet
Development

No branches or pull requests

2 participants