aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCody Hiar <cody@hiar.ca>2022-01-20 16:28:06 -0700
committerCody Hiar <cody@hiar.ca>2022-01-20 16:28:06 -0700
commita9e75625c9a1c2dd694f43b2dc443efc3db10839 (patch)
treefa98fe20e4643b3786fbd64beb73c109a6ff3ea4
parent3ad59d3ce27b29fd17f441fec84fa20abb580117 (diff)
Add
-rw-r--r--init.lua23
1 files changed, 22 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index bc6ac0a..a8dee84 100644
--- a/init.lua
+++ b/init.lua
@@ -128,7 +128,11 @@ vim.api.nvim_set_keymap('n', '<expr> k', [[(v:count > 1 ? "m'" . v:count : '') .
vim.api.nvim_set_keymap('n', '<expr> j', [[(v:count > 1 ? "m'" . v:count : '') . 'j']], { noremap = true })
-- Call Ale Fix
vim.api.nvim_set_keymap('n', '<leader>ei', '<cmd>ALEFix<cr>', { noremap = true })
-
+-- Faster quick/fix list nav
+vim.api.nvim_set_keymap('n', '[q', "<cmd>lprev<cr>", { noremap = true })
+vim.api.nvim_set_keymap('n', ']q', "<cmd>lnext<cr>", { noremap = true })
+vim.api.nvim_set_keymap('n', '[w', "<cmd>cprev<cr>", { noremap = true })
+vim.api.nvim_set_keymap('n', ']w', "<cmd>cnext<cr>", { noremap = true })
-- Build a custom status line
local status_line = {
@@ -383,4 +387,21 @@ return require('packer').startup(function()
}
use 'junegunn/goyo.vim'
use 'hashivim/vim-terraform'
+ use {
+ 'jremmen/vim-ripgrep',
+ config = function()
+ vim.cmd([[
+ nnoremap <leader>/ :call RgSearch()<CR><c-w><c-p>
+ noremap <leader>ea :Rg <cword><CR><c-w><c-p>
+ function! RgSearch()
+ call inputsave()
+ let term = input('Search: ')
+ call inputrestore()
+ if !empty(term)
+ execute "Rg " . term
+ endif
+ endfunction
+ ]])
+ end
+ }
end)