Skip to content

Add finder option ref_opt#1550

Merged
glepnir merged 3 commits intonvimdev:mainfrom
wiserfz:main
May 4, 2026
Merged

Add finder option ref_opt#1550
glepnir merged 3 commits intonvimdev:mainfrom
wiserfz:main

Conversation

@wiserfz
Copy link
Copy Markdown
Contributor

@wiserfz wiserfz commented Aug 29, 2025

Hi, thank you for such amazing plugin.

I noticed the command lspsaga finder def+ref will display the definition and the references, but the definition also include in the references section:

bashls

image

rust-analyzer

image

and I also see the issue #1336 , so I open this PR and add an option finder.ref_opt which indicated the parameters includeDeclaration for the LSP RCP method textDocument/references, the default value is true and also can be a table which can setup value for each LSP client for example:

local saga = require("lspsaga")

saga.setup({
    finder = {
      ref_opt = {
        bashls = false,
        rust_analyzer = false,
        lua_ls = true,
      },
    },
})

bashls

image

rust-analyzer

image

lua_ls

image

Any feedback is appreciated.

@wiserfz wiserfz changed the title Add finder option references_opts Add finder option ref_opt Sep 10, 2025
@wiserfz wiserfz force-pushed the main branch 2 times, most recently from a825ae6 to 3efde36 Compare September 10, 2025 03:19
@wiserfz
Copy link
Copy Markdown
Contributor Author

wiserfz commented May 4, 2026

@glepnir hi, how about this feature? Hope it can be merged.

@glepnir
Copy link
Copy Markdown
Member

glepnir commented May 4, 2026

LGTM

@glepnir glepnir merged commit 6f43686 into nvimdev:main May 4, 2026
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.

2 participants