nixos-config/home/lambda/config-files/nvim/keybinds.lua

13 lines
391 B
Lua

-- Switch between splits
vim.keymap.set("n", "<C-Right>", "<c-w>l")
vim.keymap.set("n", "<C-Left>", "<c-w>h")
vim.keymap.set("n", "<C-Up>", "<c-w>k")
vim.keymap.set("n", "<C-Down>", "<c-w>j")
-- Escape for exiting terminal mode
vim.keymap.set('t', '<Esc>', '<C-\\><C-n>')
-- move selection linewise
vim.keymap.set('v', 'J', ":m '>+1<CR>gv=gv")
vim.keymap.set('v', 'K', ":m '<-2<CR>gv=gv")