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

Code Actions refactor #453

Merged
merged 2 commits into from
Oct 31, 2023
Merged

Code Actions refactor #453

merged 2 commits into from
Oct 31, 2023

Conversation

scohen
Copy link
Collaborator

@scohen scohen commented Oct 26, 2023

After observing a PR for code actions, it seemed there was much to much busywork in creating them. This PR seeks to remedy that. Now, in order to create a code action, you just need to create a new handler in the remote_control app.

The server provider now encompasses all code actions, and handles marshalling from and to the protocol. AST transformations now reside in remote_control, which is where they belong.

Fixes #446

After observing a PR for code actions, it seemed there was much to
much busywork in creating them. This PR seeks to remedy that. Now, in
order to create a code action, you just need to create a new handler
in the `remote_control` app.

The server provider now encompasses all code actions, and handles
marshalling from and to the protocol. AST transformations now reside
in remote_control, which is where they belong.

Fixes #446
Copy link
Collaborator

@zachallaun zachallaun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a good direction to me. I think there will be at least one more change to how these work when plugins are able to provide code actions -- it might be that we want all the "built-in" handlers to just use the plugin system to register themselves. Plugin discovery happens in the remote control app though, so it's already better for these to be here.

@scohen
Copy link
Collaborator Author

scohen commented Oct 31, 2023

it might be that we want all the "built-in" handlers to just use the plugin system to register themselves.

100% agree. We need to eat our own dogfood.

@scohen scohen merged commit 24d089a into main Oct 31, 2023
7 checks passed
@scohen scohen deleted the easier-code-actions branch October 31, 2023 22:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Usability: Improve Code Actions
2 participants