Compare commits
2 commits
12dc145d06
...
aa98e13e44
Author | SHA1 | Date | |
---|---|---|---|
aa98e13e44 | |||
48819ed8b3 |
2 changed files with 22 additions and 4 deletions
|
@ -1,11 +1,11 @@
|
|||
local function map(mode, lhs, rhs, opts)
|
||||
local options = {noremap = true}
|
||||
if opts then options = vim.tbl_extend('force', options, opts) end
|
||||
vim.api.nvim_set_keymap(mode, lhs, rhs, options)
|
||||
local options = {noremap = true}
|
||||
if opts then options = vim.tbl_extend('force', options, opts) end
|
||||
vim.api.nvim_set_keymap(mode, lhs, rhs, options)
|
||||
end
|
||||
|
||||
-- Open/close nerdtree
|
||||
map('n', '<C-t>', '<cmd>NERDTreeToggle<CR>')
|
||||
map('', '<C-t>', '<cmd>NERDTreeToggle<CR>')
|
||||
|
||||
-- FZF
|
||||
map('n', '<C-f>', '<cmd>Files<CR>')
|
||||
|
@ -14,3 +14,13 @@ map('n', '<C-g>', '<cmd>Rg<CR>')
|
|||
-- Completion
|
||||
map('i', '<S-Tab>', 'pumvisible() ? "\\<C-p>" : "\\<Tab>"', {expr = true})
|
||||
map('i', '<Tab>', 'pumvisible() ? "\\<C-n>" : "\\<Tab>"', {expr = true})
|
||||
|
||||
-- Navigate between buffers
|
||||
map('n', '<C-N>', ':bn<CR>', {silent = true})
|
||||
map('n', '<C-B>', ':bp<CR>', {silent = true})
|
||||
|
||||
-- Navigate between splits
|
||||
map('n', '<C-H>', '<C-W><C-H>')
|
||||
map('n', '<C-J>', '<C-W><C-J>')
|
||||
map('n', '<C-K>', '<C-W><C-K>')
|
||||
map('n', '<C-L>', '<C-W><C-L>')
|
||||
|
|
|
@ -24,10 +24,18 @@ cmd 'highlight SignColumn guibg=transparent'
|
|||
|
||||
------ Misc -------
|
||||
|
||||
-- Split direction
|
||||
o.splitbelow = true
|
||||
o.splitright = true
|
||||
|
||||
|
||||
-- Case insensitive search
|
||||
o.ignorecase = true
|
||||
o.smartcase = true
|
||||
|
||||
-- Use mouse
|
||||
o.mouse = 'a'
|
||||
|
||||
-- Use system clipboard
|
||||
o.clipboard = 'unnamedplus'
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue