feat(nvim): add wilder as wildmenu replacement
This commit is contained in:
parent
cc001c4844
commit
d656f0dd8c
2 changed files with 36 additions and 0 deletions
|
@ -16,6 +16,9 @@
|
||||||
vim-bbye
|
vim-bbye
|
||||||
ansible-vim
|
ansible-vim
|
||||||
|
|
||||||
|
# better wildmenu
|
||||||
|
wilder-nvim
|
||||||
|
|
||||||
# ui
|
# ui
|
||||||
dressing-nvim
|
dressing-nvim
|
||||||
|
|
||||||
|
@ -162,6 +165,7 @@
|
||||||
${builtins.readFile ./dap.lua }
|
${builtins.readFile ./dap.lua }
|
||||||
${builtins.readFile ./neorg.lua }
|
${builtins.readFile ./neorg.lua }
|
||||||
${builtins.readFile ./illuminate.lua }
|
${builtins.readFile ./illuminate.lua }
|
||||||
|
${builtins.readFile ./wilder.lua }
|
||||||
|
|
||||||
vim.g.gitblame_date_format = "%r"
|
vim.g.gitblame_date_format = "%r"
|
||||||
EOF
|
EOF
|
||||||
|
|
32
neovim/wilder.lua
Normal file
32
neovim/wilder.lua
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
local wilder = require('wilder')
|
||||||
|
|
||||||
|
wilder.setup({ modes = { ':', '/', '?' } })
|
||||||
|
|
||||||
|
wilder.set_option('pipeline', {
|
||||||
|
wilder.branch(
|
||||||
|
wilder.python_file_finder_pipeline({
|
||||||
|
file_command = { "rg", "--files" },
|
||||||
|
dir_command = { 'find', '.', '-type', 'd', '-printf', '%P\n' },
|
||||||
|
filters = { 'fuzzy_filter', 'difflib_sorter' },
|
||||||
|
}),
|
||||||
|
wilder.cmdline_pipeline({
|
||||||
|
language = "python",
|
||||||
|
fuzzy = 1,
|
||||||
|
}),
|
||||||
|
wilder.python_search_pipeline({
|
||||||
|
pattern = wilder.python_fuzzy_pattern(),
|
||||||
|
sorter = wilder.python_difflib_sorter(),
|
||||||
|
engine = 're',
|
||||||
|
})
|
||||||
|
)
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Set renderer
|
||||||
|
wilder.set_option('renderer', wilder.popupmenu_renderer({
|
||||||
|
highlighter = wilder.basic_highlighter(),
|
||||||
|
left = { ' ', wilder.popupmenu_devicons() },
|
||||||
|
right = { ' ', wilder.popupmenu_scrollbar() },
|
||||||
|
pumblend = 20,
|
||||||
|
max_height = '15', -- Adjust the maximum height as needed
|
||||||
|
border = 'rounded', -- Border style can be 'single', 'double', etc.
|
||||||
|
}))
|
Loading…
Reference in a new issue