local opts = { noremap = true, silent = true } -- local term_opts = { silent = true } local keymap = vim.api.nvim_set_keymap -- Better window navigation keymap("n", "", "h", opts) keymap("n", "", "j", opts) keymap("n", "", "k", opts) keymap("n", "", "l", opts) -- Remap space as leader key keymap("n", "", "", opts) vim.g.mapleader = " " vim.g.maplocalleader = " " -- NERDTree keybindings -- keymap("n", "", ":NERDTree", opts) -- keymap("n", "", ":NERDTreeToggle", opts) -- NvimTree keybindings keymap("n", "", ":NvimTreeToggle", opts) -- Resizing windows (like i3) keymap("n", "", ":resize -2", opts) keymap("n", "", ":resize +2", opts) keymap("n", "", ":vertical resize -2", opts) keymap("n", "", ":vertical resize +2", opts) -- Moving between buffers keymap("n", "", ":bnext", opts) keymap("n", "", ":bprevious", opts) -- Move text up and down keymap("n", "", ":m .+1==", opts) keymap("n", "", ":m .-2==", opts) -- Visual mode -- keymap("v", "<", "", ">gv", opts) -- Move text up and down keymap("v", "", ":m .+1==", opts) keymap("v", "", ":m .-2==", opts) keymap("v", "p", '"_dP', opts) -- Telescope -- keymap("n", "f", "lua require 'telescope.builtin'.find_files(require('telescope.themes').get_dropdown({previewer = false}))", opts) keymap("n", "f", "Telescope find_files", opts) keymap("n", "g", "Telescope live_grep", opts) keymap("n", "m", "Telescope media_files", opts) keymap("n", "r", "Telescope lsp_references", opts) keymap("n", "h", "Telescope oldfiles", opts) -- Session Manager keymap("n", "sl", "SessionManager load_last_session", opts) keymap("n", "ss", "SessionManager save_current_session", opts) keymap("n", "so", "SessionManager load_session", opts) -- Bbye keymap("n", "q", "Bdelete", opts)