Closed prescientmoon closed 4 months ago
Yes, there is a way to do this. All special keys are implemented as buffer local mappings. Users can use special MiniStarterOpened
even to delete mappings they don't like inside an autocommand. With something like this:
require('mini.starter').setup()
local disable_ctrl_np = function()
vim.keymap.del('n', '<C-n>', { buffer = true })
vim.keymap.del('n', '<C-p>', { buffer = true })
end
vim.api.nvim_create_autocmd('User', { pattern = 'MiniStarterOpened', callback = disable_ctrl_np })
Contributing guidelines
Module(s)
mini.starter
Description
A lot of people use
C-p
in order to bring up the telescope file picker, which conflicts with the buffer-local mapping introduced bymini.starter
. I tried looking through the help file, but couldn't find a way to remove said keybind. Is there a way to do this?