nvf icon indicating copy to clipboard operation
nvf copied to clipboard

utility/telescope: custom extensions API

Open NotAShelf opened this issue 11 months ago • 1 comments

Implements a basic telescope.extensions option to take a list of additional extensions with the following schema:

[
  {
  	name = "name of the extension";
  	packages = [ <package & possible dependencies>];
    setup = {
      <extensionName> = { ... }; 
    };
  }
]

Name is used to construct the load_extension line, packages are added to vim.startPlugins verbatim and all setup attrs are merged into one to be passed to telescope's own setup table.

Fixes #542.

NotAShelf avatar Jan 14 '25 13:01 NotAShelf

:rocket: Live preview deployed from 0435104085cd714fda0147cbf8ca59ed3dee1cf9

View it here:

Debug Information

Triggered by: NotAShelf

HEAD at: telescope-ext

Reruns: 955

github-actions[bot] avatar Jan 14 '25 13:01 github-actions[bot]

I'd be interested in this! I wanna use some telescope plugins but it's quite difficult to add them as of right now.

ItsLiyua avatar Jun 03 '25 23:06 ItsLiyua

adding your extensions to startPlugins should work fine currently

horriblename avatar Jun 04 '25 07:06 horriblename

@horriblename could you remind me what the blocker was for this? I don't think API needs further work, but if there's a blocker we can probably look at resolving it for 0.8.

NotAShelf avatar Jun 04 '25 10:06 NotAShelf

it was the fact that nixpkgs telescope extensions add a duplicate telescope package, and messing up lazy loading

I think our little hack (unrelated to this PR) is still working, so we can merge this in first and worry about a proper fix later

horriblename avatar Jun 04 '25 12:06 horriblename

✅ Preview has been deleted successfully!

github-actions[bot] avatar Jun 11 '25 07:06 github-actions[bot]