Skip to content

refactor(nvim): replace telescope with snacks.picker - #50

Merged
potsrevennil merged 5 commits into
masterfrom
refactor/nvim-mini-pick-picker
Oct 21, 2026
Merged

potsrevennil merged 5 commits into
masterfrom
refactor/nvim-mini-pick-picker

Conversation

@potsrevennil

@potsrevennil potsrevennil commented Aug 17, 2026 •

Copy link
Copy Markdown
Owner

Telescope pulled in telescope.nvim, telescope-fzf-native.nvim (a compiled C sorter) and dressing.nvim. This swaps it for snacks.picker, which needs no new plugin: snacks.nvim is already a LazyVim core dependency, loaded at startup. The picker module only loads the first time a picker opens (about 8 ms, measured, same as mini.pick). Its matcher is pure Lua, so no fzf binary is needed.

The branch tried mini.pick first. It was dropped because mini.pick uses a single window: the prompt sits in the border and the preview replaces the list. snacks.picker has the fzf-style layout, with an input box, the list below it and a side preview.

  • Look at: lua/config/options.lua sets lazyvim_picker = "snacks", so LazyVim's snacks_picker extra owns the picker keymaps (<leader><space>, <leader>/, <leader>s*, …), vim.ui.select, the LSP gd/gr pickers and LazyVim.pick(). The setting is explicit because, without it, LazyVim picks a default from lazyvim.json, which differs between local installs and CI.
  • Look at: lua/config/lazy.lua adds an empty, disabled dashboard to snacks' opts before xtras. The snacks_picker extra appends a "Projects" entry to opts.dashboard, which only lazyvim.plugins.ui defines, and this repo doesn't import that. Without the stub, startup errors (snacks_picker.lua:172).
  • Lockfile: drops telescope.nvim, telescope-fzf-native.nvim and dressing.nvim; nothing is added.
  • Verify: .github/scripts/smoke-test.lua passes on a fresh Lazy! restore in an isolated data dir. In that setup, the only picker spec loaded is snacks; fzf-lua, telescope, mini.pick and dressing are absent, and lazy.nvim reports no warnings.
  • Note: master was merged into this branch (it had moved to LazyVim v16 and changed lazy.lua/the lockfile).

🤖 Generated with Claude Code

potsrevennil and others added 5 commits August 17, 2026 14:45
Swap the LazyVim telescope extra for mini.pick + mini.extra: a
single-file, pure-Lua picker (no fzf dependency) with rg/git as optional
accelerators that warn-not-fail when absent. files() falls back to a Lua
directory walk without rg/fd. Keymaps mirror LazyVim's published scheme
so muscle memory and its cheatsheet still apply; only the RHS changes.

lazyvim_picker was inert (never read at runtime) and the telescope
picker keymaps lived entirely in the extra, so removing the import drops
telescope + telescope-fzf-native cleanly with nothing to reconcile.
plenary is retained (codecompanion/none-ls still require it).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Dropping vim.g.lazyvim_picker made LazyVim auto-enable its editor.fzf
extra, which installed fzf-lua and bound <leader><space>, <leader>/, ...
over mini.pick's keys, so file search and live grep opened different UIs.

Claim that extra's import name before lazyvim.plugins.xtras so lazy.nvim
skips it, and register mini.pick as LazyVim.pick()'s backend there
(dashboard entries, <leader>fc). Also send vim.ui.select through
mini.pick before it is lazy-loaded, and repoint LazyVim's Snacks.picker
git log keymaps (<leader>gl/gL/gf) at mini.extra.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…g it

Claiming the editor.fzf import name only worked when lazyvim.json made
fzf the default; CI has no lazyvim.json, so LazyVim picked snacks_picker
and loaded it anyway. The fake lazyvim.plugins.extras.* name also sat
before the core imports and tripped the smoke test's order check.

Mark every picker-group default extra disabled instead, which LazyVim's
import hook and xtras both honour, from an import not named
lazyvim.plugins.* so the order check ignores it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
mini.pick draws everything in one window: the prompt sits in the border
and the preview replaces the list. snacks.picker has the fzf-style
layout (input box, list, side preview), and snacks.nvim is already a
LazyVim core dependency, loaded at startup -- so this drops mini.pick and
mini.extra rather than adding anything.

Set vim.g.lazyvim_picker = "snacks" and let LazyVim's snacks_picker extra
own the keymaps, vim.ui.select, LSP pickers and LazyVim.pick(). That
extra appends to opts.dashboard, which only lazyvim.plugins.ui defines,
so give snacks an empty, disabled dashboard before xtras is imported.
Drops telescope, telescope-fzf-native and dressing.nvim from the lock.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@potsrevennil potsrevennil changed the title refactor(nvim): replace telescope with mini.pick as the picker refactor(nvim): replace telescope with snacks.picker Oct 20, 2026
@potsrevennil
potsrevennil marked this pull request as ready for review October 21, 2026 15:49
@potsrevennil
potsrevennil merged commit c4fa01b into master Oct 21, 2026
10 of 11 checks passed
@potsrevennil
potsrevennil deleted the refactor/nvim-mini-pick-picker branch October 21, 2026 15:50
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.

1 participant