Update nvim config.

This commit is contained in:
Devin Lumley 2022-11-22 18:25:35 -08:00
parent d65a5daf96
commit 83a6862734
8 changed files with 171 additions and 11 deletions

View file

@ -11,6 +11,16 @@ mapper("n", "gd", ":vs | lua vim.lsp.buf.definition()<CR>") -- open defn in a ne
if no_plugins then return end
-- Telescope integration
local telescope_builtin = require("telescope.builtin")
mapper("n", "<C-p>", telescope_builtin.find_files) -- search all files, respecting .gitignore if one exists
mapper("n", "<Leader>ff", telescope_builtin.find_files) -- search all files, respecting .gitignore if one exists
mapper("n", "<Leader>fb", telescope_builtin.buffers) -- search open buffers
mapper("n", "<Leader>fl", telescope_builtin.current_buffer_fuzzy_find) -- search lines in current buffer
mapper("n", "<Leader>gg", telescope_builtin.live_grep) -- search all lines in project
mapper("n", "<Leader>fr", telescope_builtin.lsp_references) -- search references to symbol under cursor
mapper("n", "<Leader>gc", telescope_builtin.git_branches) -- checkout different branches
-- Git things
mapper("n", "<Leader>gs", ":vs Git<CR>") -- `git status` in a new tab to save screen real estate
mapper("n", "<Leader>gd", "<cmd>Gdiffsplit<CR>") -- open a split diffing the current file