diff options
Diffstat (limited to 'lua/pml68/remap.lua')
| -rw-r--r-- | lua/pml68/remap.lua | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/lua/pml68/remap.lua b/lua/pml68/remap.lua index 1456161..c1fe1c7 100644 --- a/lua/pml68/remap.lua +++ b/lua/pml68/remap.lua @@ -50,3 +50,18 @@ vim.api.nvim_create_autocmd('LspAttach', { vim.keymap.set('n', '<F4>', '<cmd>lua vim.lsp.buf.code_action()<cr>', opts) end }) + +-- Netrw (u/vonheikemen) +vim.api.nvim_create_autocmd('filetype', { + pattern = 'netrw', + desc = 'Better mappings for netrw', + callback = function() + local bind = function(lhs, rhs) + vim.keymap.set('n', lhs, rhs, {remap = true, buffer = true}) + end + + bind('a', '%') + + bind('r', 'R') + end +}) |
