-
-
Notifications
You must be signed in to change notification settings - Fork 509
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
feat(oxc_language_server): implement oxc.fixAll
workspace command
#8858
Conversation
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. |
I've added some notes that I'd like to have your input on 😀 |
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.
Nice work. I could not test it (see one discussion) but from the outside this looks great 👍
@Sysix Do you perhaps have The commands in package.json are only the |
How do I tell vscode to execute the LSP Command?
Yes. But it still works (somehow). I printed the vscode ClientCapability with this method for you. |
I don't think that you can directly exefute the LSP command without the use of a plugin. It's more like an interface for an editor to use - This PR updates the vscode command to use the new LSP command, so if the |
Thanks for the explanation. I tested this command. worked! |
CodSpeed Performance ReportMerging #8858 will not alter performanceComparing Summary
|
…S tests, update fixall label
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.
thanks you. there can probably be more optimization done in this package.
## [0.15.10] - 2025-02-06 ### Features - d6d80f7 linter: Add suggestion fixer for `eslint/no-iterator` (#8894) (dalaoshu) - 7e8568b linter: Junit reporter (#8756) (Tapan Prakash) - f4662a9 oxc_language_server: Implement `oxc.fixAll` workspace command (#8858) (Marek Vospel) ### Bug Fixes - baf3e4e linter: Correctly replace rule severity with duplicate rule name configurations (#8840) (dalaoshu) ### Performance - 8a4988d linter: Use parallel iterator directly instead of iter and parallel bridge (#8831) (Cam McHenry) ### Refactor - bb9d763 linter: Remove usage of `url` crate (#8833) (camchenry) - 4fcf719 linter: Replace MIME guessing with extension check (#8832) (camchenry) Co-authored-by: Boshen <[email protected]>
This pull request focuses on optimizing the implementation of the
oxlint.applyAllFixesFile
vscode command by adding the command interface to the LSP instead of requesting all code actions and executing the preferred ones. This PR contains an abstraction above the LSP workspace commands, theoxc.fixAll
command itself and minor changes to the vscode extension.Since the
workspace/executeCommand
handler is new, I've created an abstraction to register the commands and parse their arguments. While it isn't necessary, I feel like it makes future additions to the LS easier.I tested the command in both vscode and neovim, doubt it will be hard to use this in the zed / intellij projects.