27 lines
847 B
Lua
27 lines
847 B
Lua
-- Settings leader as space. Leader is requred for all custom keybinds
|
|
vim.g.mapleader = " "
|
|
-- Enters netrw/file explore in nvim
|
|
vim.keymap.set("n", "<leader>pv", vim.cmd.Ex)
|
|
|
|
-- Lests you move visual marked blocks up and down
|
|
vim.keymap.set("v", "J", ":m '>+1<CR>gv=gv")
|
|
vim.keymap.set("v", "K", ":m '<-2<CR>gv=gv")
|
|
|
|
-- Lets you move the line below onto current line
|
|
vim.keymap.set("n", "J", "mzJ`z")
|
|
|
|
-- Lets you jump half page up and down
|
|
vim.keymap.set("n", "<C-d>", "<C-d>zz")
|
|
vim.keymap.set("n", "<C-u>", "<C-u>zz")
|
|
|
|
-- Lets you paste without swapping the yoink/paste buffer
|
|
vim.keymap.set("x", "<leader>p", [["_dP]])
|
|
|
|
-- Lets you yoink into clipboard
|
|
vim.keymap.set({"n", "v"}, "<leader>y", [["+y]])
|
|
vim.keymap.set("n", "<leader>Y", [["+Y]])
|
|
|
|
-- Ctrl-c remap to Esc
|
|
vim.keymap.set("i", "<C-c>", "<Esc>")
|
|
|
|
vim.keymap.set("n", "Q", "<nop>") |