Files
code/basic/nvim/plugconf/vimux.lua
2023-06-10 14:54:31 +02:00

14 lines
413 B
Lua

-- Hack to replace dropped -p parameter
vim.g.VimuxHeight = '0 -l 20%'
-- Keyboard shortcuts
if vim.env.TMUX ~= nil then
vim.keymap.set('n', '<f5>', function()
vim.cmd.write()
local file = vim.api.nvim_buf_get_name(0)
local command = vim.g.vimux_command or 'make'
vim.fn.VimuxRunCommand(command:format(file))
end)
vim.keymap.set('n', '<f6>', vim.fn.VimuxCloseRunner, { silent = true })
end