fix(lazygit): dont use <esc><esc>
for normal more for laygit to prevent delays on <esc>
. Fixes #567
This commit is contained in:
@ -102,15 +102,17 @@ function M.telescope(builtin, opts)
|
||||
end
|
||||
end
|
||||
|
||||
-- FIXME: create a togglable terminal
|
||||
-- Opens a floating terminal (interactive by default)
|
||||
---@param cmd? string[]|string
|
||||
---@param opts? LazyCmdOptions|{interactive?:boolean}
|
||||
---@param opts? LazyCmdOptions|{interactive?:boolean, esc_esc?:false}
|
||||
function M.float_term(cmd, opts)
|
||||
opts = vim.tbl_deep_extend("force", {
|
||||
size = { width = 0.9, height = 0.9 },
|
||||
}, opts or {})
|
||||
require("lazy.util").float_term(cmd, opts)
|
||||
local float = require("lazy.util").float_term(cmd, opts)
|
||||
if opts.esc_esc == false then
|
||||
vim.keymap.set("t", "<esc>", "<esc>", { buffer = float.buf, nowait = true })
|
||||
end
|
||||
end
|
||||
|
||||
---@param silent boolean?
|
||||
|
Reference in New Issue
Block a user