summaryrefslogtreecommitdiff
path: root/plugin/maps.vim
diff options
context:
space:
mode:
authorAkshay <[email protected]>2021-02-15 08:52:32 +0000
committerAkshay <[email protected]>2021-02-15 08:52:32 +0000
commitfcaf13a267b7bacd26ad8b2e952a793645e42bba (patch)
tree6e795b46b1fbefb05151e95c0346951d67fac4e7 /plugin/maps.vim
init
Diffstat (limited to 'plugin/maps.vim')
-rw-r--r--plugin/maps.vim46
1 files changed, 46 insertions, 0 deletions
diff --git a/plugin/maps.vim b/plugin/maps.vim
new file mode 100644
index 0000000..188cb69
--- /dev/null
+++ b/plugin/maps.vim
@@ -0,0 +1,46 @@
1mapclear
2
3let mapleader=' '
4
5" clipboard
6map <leader>cc :w !xclip -sel c<CR>
7
8" normal
9nnoremap <Leader>o : only<cr>
10" nnoremap <Leader>l : Lines<cr>
11nnoremap <Leader>b : Buffers<cr>
12nnoremap <Leader>n : bnext<cr>
13nnoremap <Leader>p : bprev<cr>
14nnoremap <Leader>z : FZF<cr>
15nnoremap <Leader>l : Lines<cr>
16nnoremap <Leader>w : MtaJumpToOtherTag<cr>
17nnoremap <Leader>t : call GetTabber()<cr>
18nnoremap <Leader><ESC> : nohlsearch<cr>
19nnoremap <C-l> :nohlsearch<cr>:diffupdate<cr>:syntax sync fromstart<cr><c-l>
20nnoremap H H:exec 'norm! '. &scrolloff . 'k'<cr>
21nnoremap L L:exec 'norm! '. &scrolloff . 'j'<cr>
22nnoremap <expr> gb '`[' . strpart(getregtype(), 0, 1) . '`]'
23
24
25nnoremap <F10> :echo "hi<" . synIDattr(synID(line("."),col("."),1),"name") . '> trans<'
26 \ . synIDattr(synID(line("."),col("."),0),"name") . "> lo<"
27 \ . synIDattr(synIDtrans(synID(line("."),col("."),1)),"name") . ">"<CR>
28
29cmap w!! %!sudo -S tee > /dev/null %
30
31" visual
32vnoremap > >gv
33vnoremap < <gv
34
35" operator-pending
36onoremap ax a`
37onoremap ix i`
38
39" visual block
40xnoremap + g<C-a>
41xnoremap - g<C-x>
42
43" completions
44inoremap <silent><expr> <C-Space> compe#complete()
45inoremap <silent><expr> <CR> compe#confirm('<CR>')
46inoremap <silent><expr> <C-e> compe#close('<C-e>')