diff options
| author | anott03 <amitav_nott@ryecountryday.org> | 2021-01-27 11:22:11 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-01-27 17:22:11 +0100 |
| commit | 5995a8be8faaa2c6e8693ca52f2320cb4a80e3fa (patch) | |
| tree | a3fe0a4f64074a1834df3b80e1445cb725b9fdb1 /lua/telescope/builtin/internal.lua | |
| parent | ccbb7f56384921a81813f0f9ebc85cdba0b7c255 (diff) | |
Undo #465 (#469)
We have broke all extension that do some sort of goto_file_selection:replace
Problem described here: https://github.com/nvim-telescope/telescope.nvim/pull/465#issuecomment-767831897
Possible solution: https://github.com/nvim-telescope/telescope.nvim/pull/465#issuecomment-767808213
Diffstat (limited to 'lua/telescope/builtin/internal.lua')
| -rw-r--r-- | lua/telescope/builtin/internal.lua | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/lua/telescope/builtin/internal.lua b/lua/telescope/builtin/internal.lua index d09f554..3c34b8b 100644 --- a/lua/telescope/builtin/internal.lua +++ b/lua/telescope/builtin/internal.lua @@ -47,7 +47,7 @@ internal.builtin = function(opts) previewer = previewers.builtin.new(opts), sorter = conf.generic_sorter(opts), attach_mappings = function(_) - actions.select:replace(actions.run_builtin) + actions.goto_file_selection_edit:replace(actions.run_builtin) return true end }):find() @@ -82,7 +82,7 @@ internal.planets = function(opts) previewer = previewers.cat.new(opts), sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() actions.close(prompt_bufnr) @@ -137,7 +137,7 @@ internal.symbols = function(opts) }, sorter = conf.generic_sorter(opts), attach_mappings = function(_) - actions.select:replace(actions.insert_symbol) + actions.goto_file_selection_edit:replace(actions.insert_symbol) return true end }):find() @@ -168,7 +168,7 @@ internal.commands = function(opts) }, sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() actions.close(prompt_bufnr) local val = selection.value @@ -285,7 +285,7 @@ internal.vim_options = function(opts) -- previewer = previewers.help.new(opts), sorter = conf.generic_sorter(opts), attach_mappings = function() - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() local esc = "" @@ -411,7 +411,7 @@ internal.help_tags = function(opts) previewer = previewers.help.new(opts), sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions._select:replace(function(_, cmd) + actions._goto_file_selection:replace(function(_, cmd) local selection = actions.get_selected_entry() actions.close(prompt_bufnr) if cmd == 'edit' or cmd == 'new' then @@ -440,7 +440,7 @@ internal.man_pages = function(opts) previewer = previewers.man.new(opts), sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions._select:replace(function(_, cmd) + actions._goto_file_selection:replace(function(_, cmd) local selection = actions.get_selected_entry() actions.close(prompt_bufnr) @@ -483,7 +483,7 @@ internal.reloader = function(opts) sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() actions.close(prompt_bufnr) @@ -562,7 +562,7 @@ internal.colorscheme = function(opts) -- TODO: better preview? sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() actions.close(prompt_bufnr) @@ -614,7 +614,7 @@ internal.registers = function(opts) -- use levenshtein as n-gram doesn't support <2 char matches sorter = sorters.get_levenshtein_sorter(), attach_mappings = function(_, map) - actions.select:replace(actions.paste_register) + actions.goto_file_selection_edit:replace(actions.paste_register) map('i', '<C-e>', actions.edit_register) return true @@ -653,7 +653,7 @@ internal.keymaps = function(opts) }, sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() vim.api.nvim_feedkeys( vim.api.nvim_replace_termcodes(selection.value.lhs, true, false, true), @@ -675,7 +675,7 @@ internal.filetypes = function(opts) }, sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() actions.close(prompt_bufnr) vim.cmd('setfiletype ' .. selection[1]) @@ -696,7 +696,7 @@ internal.highlights = function(opts) }, sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() actions.close(prompt_bufnr) vim.cmd('hi ' .. selection.value) @@ -787,7 +787,7 @@ internal.autocommands = function(opts) previewer = previewers.autocommands.new(opts), sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions._select:replace(function(_, vim_cmd) + actions._goto_file_selection:replace(function(_, vim_cmd) local selection = actions.get_selected_entry() actions.close(prompt_bufnr) vim.cmd(vim_cmd .. ' ' .. selection.value) @@ -811,7 +811,7 @@ internal.spell_suggest = function(opts) }, sorter = conf.generic_sorter(opts), attach_mappings = function(prompt_bufnr) - actions.select:replace(function() + actions.goto_file_selection_edit:replace(function() local selection = actions.get_selected_entry() actions.close(prompt_bufnr) vim.cmd('normal! ciw' .. selection[1]) |
