Skip to content

Commit 134477b

Browse files
committed
fix: do not feedkeys on 0.11.6 (closes #2541)
1 parent c9e0738 commit 134477b

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

lua/fzf-lua/fzf.lua

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,8 +185,11 @@ function M.raw_fzf(contents, fzf_cli_args, opts)
185185
if fzfwin then fzfwin:update_statusline() end
186186

187187
-- See note in "ModeChanged" above
188-
189-
if not utils.__HAS_NVIM_012 and vim.api.nvim_get_mode().mode == "t" then
188+
-- NOTE: feedkeys hack not required since
189+
-- https://github.com/neovim/neovim/commit/3621af9b970c80d2a6ff36569d7495391599c334
190+
if not (utils.__HAS_NVIM_012 or utils.__HAS_NVIM_0116)
191+
and vim.api.nvim_get_mode().mode == "t"
192+
then
190193
-- Called from another fzf-win most likely
191194
utils.feed_keys_termcodes("i")
192195
else

lua/fzf-lua/utils.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ local M = {}
1515
M.__HAS_NVIM_010 = vim.fn.has("nvim-0.10") == 1
1616
M.__HAS_NVIM_0102 = vim.fn.has("nvim-0.10.2") == 1
1717
M.__HAS_NVIM_011 = vim.fn.has("nvim-0.11") == 1
18+
M.__HAS_NVIM_0116 = vim.fn.has("nvim-0.11.6") == 1
1819
M.__HAS_NVIM_012 = vim.fn.has("nvim-0.12") == 1
1920
M.__IS_WINDOWS = vim.fn.has("win32") == 1 or vim.fn.has("win64") == 1
2021
-- `:help shellslash` (for more info see #1055)

0 commit comments

Comments
 (0)