diff options
author | Squibid <me@zacharyscheiman.com> | 2025-01-24 13:56:11 -0600 |
---|---|---|
committer | Squibid <me@zacharyscheiman.com> | 2025-01-24 13:56:11 -0600 |
commit | 8eaa615596be321a3be12378c5e7d65cc7e482b6 (patch) | |
tree | 53fe601048ea302962420de4feff465e4c7d9317 /lua/conf/binds.lua | |
parent | a0ebc39b59a98a69fbb6abf150f86dc4e19987a3 (diff) | |
download | nvim-master.tar.gz nvim-master.tar.bz2 nvim-master.zip |
Diffstat (limited to 'lua/conf/binds.lua')
-rw-r--r-- | lua/conf/binds.lua | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/lua/conf/binds.lua b/lua/conf/binds.lua index 2f5673a..1426ac3 100644 --- a/lua/conf/binds.lua +++ b/lua/conf/binds.lua @@ -14,8 +14,8 @@ map('v', '<S-j>', ":m '>+1<CR>gv=gv", { desc = 'Move selected text down.' }) map('n', '<S-j>', 'mzJ`z<cmd>delm z<CR>') -- when combining lines map('n', 'n', 'nzzzv') -- when searching map('n', 'N', 'Nzzzv') -map('n', '<C-d>', '<C-d>zz') -- half page jumping -map('n', '<C-u>', '<C-u>zz') +map('n', '<C-d>', '<C-d>zzzv') -- half page jumping +map('n', '<C-u>', '<C-u>zzzv') map('n', '<leader>x', function() -- execute order 111 local fn = vim.fn.expand("%:p") @@ -33,12 +33,6 @@ map('n', '<leader>x', function() -- execute order 111 end end, { desc = 'toggle executable flag of the file' }) --- tabs -map('n', '[]', '<cmd>tabnew<CR>') -map('n', '][', '<cmd>tabc<CR>') -map('n', '[[', '<cmd>tabp<CR>') -map('n', ']]', '<cmd>tabn<CR>') - -- good spell suggestion ui -- (stolen from https://github.com/neovim/neovim/pull/25833) vim.keymap.set('n', 'z=', function() @@ -56,3 +50,11 @@ vim.keymap.set('n', 'z=', function() local prompt = 'Change '..vim.inspect(cword)..' to:' vim.ui.select(vim.fn.spellsuggest(cword, vim.o.lines), { prompt = prompt }, spell_on_choice) end, { desc = 'Shows spelling suggestions' }) + +-- quickfix +map('n', '<M-j>', '<cmd>cnext<CR>zz') +map('n', '<M-k>', '<cmd>cprev<CR>zz') +map('n', '<M-c>', '<cmd>cclose<CR>') + +-- open up Ex +map('n', '<leader>c', '<cmd>Ex<CR>') |