From f3d9ef138df7f531434ce3ff37fcd379517d8640 Mon Sep 17 00:00:00 2001 From: ChristianChiarulli Date: Thu, 4 Nov 2021 15:49:41 -0400 Subject: fix: make telescope default mappings overrideable --- lua/lvim/core/telescope.lua | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'lua/lvim/core') diff --git a/lua/lvim/core/telescope.lua b/lua/lvim/core/telescope.lua index 7911d433..7a5315dd 100644 --- a/lua/lvim/core/telescope.lua +++ b/lua/lvim/core/telescope.lua @@ -8,6 +8,7 @@ function M.config() on_config_done = nil, } + local actions = require "telescope.actions" lvim.builtin.telescope = vim.tbl_extend("force", lvim.builtin.telescope, { defaults = { prompt_prefix = " ", @@ -33,6 +34,22 @@ function M.config() "--smart-case", "--hidden", }, + mappings = { + i = { + [""] = actions.move_selection_next, + [""] = actions.move_selection_previous, + [""] = actions.close, + [""] = actions.cycle_history_next, + [""] = actions.cycle_history_prev, + [""] = actions.smart_send_to_qflist + actions.open_qflist, + [""] = actions.select_default + actions.center, + }, + n = { + [""] = actions.move_selection_next, + [""] = actions.move_selection_previous, + [""] = actions.smart_send_to_qflist + actions.open_qflist, + }, + }, file_ignore_patterns = {}, path_display = { shorten = 5 }, winblend = 0, -- cgit v1.2.3