blob: 790d21bfd1976254c2794f05a0190cee30a27846 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
(import-macros {: map!} :nvrc.macro.keymap)
(import-macros {: setv!} :nvrc.macro.set)
(map! [n] :<space> "" "")
(setv! mapleader " ")
(map! [n :silent] :<leader>fe ":NvimTreeToggle <cr>")
(map! [n :silent] :<leader>ft ":NvimTreeFocus <cr>")
(map! [n :silent] :<leader>/
":lua require('Comment.api').toggle_current_linewise() <cr>")
(map! [v :silent] :<leader>/
":lua require('Comment.api').toggle_linewise_op(vim.fn.visualmode()) <cr>")
(map! [n :silent] :<leader>ff ":FzfLua files <cr>")
(map! [n :silent] :<leader>fc ":FzfLua grep <cr>")
(map! [n :silent] :<leader>fs ":FzfLua live_grep <cr>")
(map! [n :silent] :<leader>fb ":FzfLua buffers <cr>")
(map! [n :silent] :<leader>gc ":FzfLua git_commits <cr>")
(map! [n :silent] :<leader>gs ":FzfLua git_status <cr>")
(map! [n] :f :<plug>Lightspeed_f)
(map! [n] :F :<plug>Lightspeed_F)
(map! [n] :t :<plug>Lightspeed_t)
(map! [n] :T :<plug>Lightspeed_T)
(map! [n :silent] :<leader>rm ":TZMinimalist <cr>")
(map! [n :silent] :<leader>rf ":TZFocus <cr>")
(map! [n :silent] :<leader>ra ":TZAtaraxis <cr>")
(map! [t] :jk "<C-\\><C-n>")
(map! [t :silent] :JK "<C-\\><C-n> :lua require ('nvrc.utils').del_buf() <cr>")
; FIXME This opens on top of existing vertical/horizontal term
(map! [n :silent] :<leader>th ":execute 15 .. 'new +terminal' | let b:term_type = 'hori' <cr>")
(map! [n :silent] :<leader>tv ":execute 'vnew +terminal' | let b:term_type = 'vert' <cr>")
(map! [n :silent] :<leader>tn ":execute 'terminal' | let b:term_type = 'wind' <cr>")
(map! [n :silent] :<leader>q ":lua require('nvrc.utils').del_buf() <cr>")
(map! [n :silent] :<leader>ya ":%y+ <cr>")
(map! [n :silent] :<leader>bn ":enew <cr>")
(map! [n :silent] :<leader>wn ":tabnew <cr>")
(map! [n :silent] :<leader>lt ":set nu! <cr>")
|