diff --git a/README.md b/README.md index 0afb079..0e4dc10 100644 --- a/README.md +++ b/README.md @@ -439,6 +439,7 @@ require'fzf-lua'.setup { -- pager = "delta", -- if you have `delta` installed }, man = { + -- NOTE: remove the `-c` flag when using man-db cmd = "man -c %s | col -bx", }, builtin = { diff --git a/doc/fzf-lua.txt b/doc/fzf-lua.txt index f683673..6a84e5e 100644 --- a/doc/fzf-lua.txt +++ b/doc/fzf-lua.txt @@ -484,6 +484,7 @@ Consult the list below for available settings: -- pager = "delta", -- if you have `delta` installed }, man = { + -- NOTE: remove the `-c` flag when using man-db cmd = "man -c %s | col -bx", }, builtin = { diff --git a/lua/fzf-lua/providers/grep.lua b/lua/fzf-lua/providers/grep.lua index e47ca16..f6c8c7b 100644 --- a/lua/fzf-lua/providers/grep.lua +++ b/lua/fzf-lua/providers/grep.lua @@ -115,7 +115,8 @@ M.grep = function(opts) opts.__MODULE__ = opts.__MODULE__ or M local no_esc = false - if opts.continue_last_search or opts.repeat_last_search then + if not opts.search and + (opts.continue_last_search or opts.repeat_last_search) then opts.search, no_esc = get_last_search(opts) opts.search = opts.search or opts.continue_last_search_default end @@ -176,7 +177,8 @@ M.live_grep_st = function(opts) assert(not opts.multiprocess) local no_esc = false - if opts.continue_last_search or opts.repeat_last_search then + if not opts.search and + (opts.continue_last_search or opts.repeat_last_search) then opts.search, no_esc = get_last_search(opts) end @@ -248,7 +250,8 @@ M.live_grep_mt = function(opts) assert(opts.multiprocess) local no_esc = false - if opts.continue_last_search or opts.repeat_last_search then + if not opts.search and + (opts.continue_last_search or opts.repeat_last_search) then opts.search, no_esc = get_last_search(opts) end diff --git a/lua/fzf-lua/providers/tags.lua b/lua/fzf-lua/providers/tags.lua index 22f7c1e..0beb396 100644 --- a/lua/fzf-lua/providers/tags.lua +++ b/lua/fzf-lua/providers/tags.lua @@ -143,7 +143,8 @@ end M.grep = function(opts) opts = opts or {} - if opts.continue_last_search or opts.repeat_last_search then + if not opts.search and + (opts.continue_last_search or opts.repeat_last_search) then opts.search, opts.no_esc = M.get_last_search(opts) opts.search = opts.search or opts.continue_last_search_default end