disable 'ctrl-g' for l|grep_curbuf, hide filename in 'blines'

main
bhagwan 2 years ago
parent ac4fa2a302
commit bca2107b63

@ -371,7 +371,7 @@ M.globals.blines = {
show_unlisted = true,
no_term_buffers = false,
fzf_opts = {
['--delimiter'] = "'[\\]:]'",
['--delimiter'] = "'[:]'",
["--with-nth"] = '2..',
["--tiebreak"] = 'index',
},
@ -401,7 +401,7 @@ M.globals.btags = {
git_icons = true,
color_icons = true,
fzf_opts = {
['--delimiter'] = "'[\\]:]'",
['--delimiter'] = "'[:]'",
["--with-nth"] = '2..',
["--tiebreak"] = 'index',
},

@ -469,6 +469,11 @@ M.grep_curbuf = function(opts)
opts.fzf_opts = vim.tbl_extend("keep",
opts.fzf_opts or {}, config.globals.blines.fzf_opts)
opts.filename = vim.api.nvim_buf_get_name(0)
-- disable ctrl-g switch by default
if not opts.actions or not opts.actions["ctrl-g"] then
opts.actions = opts.actions or {}
opts.actions["ctrl-g"] = false
end
if #opts.filename > 0 and vim.loop.fs_stat(opts.filename) then
opts.filename = path.relative(opts.filename, vim.loop.cwd())
if opts.lgrep then

Loading…
Cancel
Save