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

Check for rename support before showing LSP rename prompt #9277

Merged
merged 1 commit into from
Jan 9, 2024

Conversation

the-mikedavis
Copy link
Member

Previously we always showed the prompt even if the current document didn't have a language server that could perform a rename. For example we showed a rename prompt even when using <space>r in a scratch buffer.

Instead we should check the document's language servers to see if any supports a rename and bail if there are none.

This was originally #6249 (fixed in #6257) but regressed in #2507

Previously we always showed the prompt even if the current document
didn't have a language server that could perform a rename. For example
we showed a rename prompt even when using `<space>r` in a scratch
buffer.

Instead we should check the document's language servers to see if any
supports a rename and bail if there are none.
@the-mikedavis the-mikedavis added C-bug Category: This is a bug E-easy Call for participation: Experience needed to fix: Easy / not much S-waiting-on-review Status: Awaiting review from a maintainer. A-command Area: Commands labels Jan 8, 2024
Copy link
Member

@pascalkuthe pascalkuthe left a comment

Choose a reason for hiding this comment

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

good catch!

@pascalkuthe pascalkuthe added this to the next milestone Jan 8, 2024
@archseer archseer merged commit 0cbd8d3 into master Jan 9, 2024
6 checks passed
@archseer archseer deleted the lsp-check-rename-capability branch January 9, 2024 00:55
mtoohey31 pushed a commit to mtoohey31/helix that referenced this pull request Jun 2, 2024
Vulpesx pushed a commit to Vulpesx/helix that referenced this pull request Jun 7, 2024
smortime pushed a commit to smortime/helix that referenced this pull request Jul 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-command Area: Commands C-bug Category: This is a bug E-easy Call for participation: Experience needed to fix: Easy / not much S-waiting-on-review Status: Awaiting review from a maintainer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants