feat(extras): added extra for snacks picker

This commit is contained in:
Folke Lemaitre 2025-01-11 00:40:35 +01:00
parent d1529f650f
commit 6bdeeac529
No known key found for this signature in database
GPG key ID: 41F8B1FBACAE2040
4 changed files with 100 additions and 2 deletions

View file

@ -42,11 +42,13 @@ function M.register(picker)
return true
end
---@return "telescope" | "fzf"
---@return "telescope" | "fzf" | "snacks"
function M.want()
vim.g.lazyvim_picker = vim.g.lazyvim_picker or "auto"
if vim.g.lazyvim_picker == "auto" then
return LazyVim.has_extra("editor.telescope") and "telescope" or "fzf"
return LazyVim.has_extra("editor.snacks_picker") and "snacks"
or LazyVim.has_extra("editor.telescope") and "telescope"
or "fzf"
end
return vim.g.lazyvim_picker
end