-
Notifications
You must be signed in to change notification settings - Fork 1
/
.nvimrc
146 lines (146 loc) · 7.77 KB
/
.nvimrc
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
version 6.0
let s:cpo_save=&cpo
set cpo&vim
inoremap <silent> <Plug>NERDCommenterInsert :call nerdcommenter#Comment('i', "Insert")
inoremap <silent> <C-Tab> =UltiSnips#ListSnippets()
inoremap <M-k> :m .-2==gi
inoremap <M-j> :m .+1==gi
snoremap <silent> "_c
nnoremap h
xnoremap <silent> :call UltiSnips#SaveLastVisualSelection()gvs
snoremap <silent> :call UltiSnips#ExpandSnippet()
nnoremap <NL> j
nnoremap k
nnoremap l
snoremap "_c
nmap ca <Plug>NERDCommenterAltDelims
xmap cu <Plug>NERDCommenterUncomment
nmap cu <Plug>NERDCommenterUncomment
xmap cb <Plug>NERDCommenterAlignBoth
nmap cb <Plug>NERDCommenterAlignBoth
xmap cl <Plug>NERDCommenterAlignLeft
nmap cl <Plug>NERDCommenterAlignLeft
nmap cA <Plug>NERDCommenterAppend
xmap cy <Plug>NERDCommenterYank
nmap cy <Plug>NERDCommenterYank
xmap cs <Plug>NERDCommenterSexy
nmap cs <Plug>NERDCommenterSexy
xmap ci <Plug>NERDCommenterInvert
nmap ci <Plug>NERDCommenterInvert
nmap c$ <Plug>NERDCommenterToEOL
xmap cn <Plug>NERDCommenterNested
nmap cn <Plug>NERDCommenterNested
xmap cm <Plug>NERDCommenterMinimal
nmap cm <Plug>NERDCommenterMinimal
xmap c <Plug>NERDCommenterToggle
nmap c <Plug>NERDCommenterToggle
xmap cc <Plug>NERDCommenterComment
nmap cc <Plug>NERDCommenterComment
omap <silent> % <Plug>(MatchitOperationForward)
xmap <silent> % <Plug>(MatchitVisualForward)
nmap <silent> % <Plug>(MatchitNormalForward)
nnoremap Y y$
omap <silent> [% <Plug>(MatchitOperationMultiBackward)
xmap <silent> [% <Plug>(MatchitVisualMultiBackward)
nmap <silent> [% <Plug>(MatchitNormalMultiBackward)
omap <silent> ]% <Plug>(MatchitOperationMultiForward)
xmap <silent> ]% <Plug>(MatchitVisualMultiForward)
nmap <silent> ]% <Plug>(MatchitNormalMultiForward)
xmap a% <Plug>(MatchitVisualTextObject)
xmap gx <Plug>NetrwBrowseXVis
nmap gx <Plug>NetrwBrowseX
omap <silent> g% <Plug>(MatchitOperationBackward)
xmap <silent> g% <Plug>(MatchitVisualBackward)
nmap <silent> g% <Plug>(MatchitNormalBackward)
nnoremap gf :vert winc f" copies filepath to clipboard by pressing yf
vnoremap jk
vnoremap kj
nnoremap <silent> yd :let @+=expand('%:p:h')" Vim jump to the last position when reopening a file
nnoremap <silent> yf :let @+=expand('%:p')
xnoremap <silent> <Plug>NetrwBrowseXVis :call netrw#BrowseXVis()
nnoremap <silent> <Plug>NetrwBrowseX :call netrw#BrowseX(netrw#GX(),netrw#CheckIfRemote(netrw#GX()))
xmap <silent> <Plug>(MatchitVisualTextObject) <Plug>(MatchitVisualMultiBackward)o<Plug>(MatchitVisualMultiForward)
onoremap <silent> <Plug>(MatchitOperationMultiForward) :call matchit#MultiMatch("W", "o")
onoremap <silent> <Plug>(MatchitOperationMultiBackward) :call matchit#MultiMatch("bW", "o")
xnoremap <silent> <Plug>(MatchitVisualMultiForward) :call matchit#MultiMatch("W", "n")m'gv``
xnoremap <silent> <Plug>(MatchitVisualMultiBackward) :call matchit#MultiMatch("bW", "n")m'gv``
nnoremap <silent> <Plug>(MatchitNormalMultiForward) :call matchit#MultiMatch("W", "n")
nnoremap <silent> <Plug>(MatchitNormalMultiBackward) :call matchit#MultiMatch("bW", "n")
onoremap <silent> <Plug>(MatchitOperationBackward) :call matchit#Match_wrapper('',0,'o')
onoremap <silent> <Plug>(MatchitOperationForward) :call matchit#Match_wrapper('',1,'o')
xnoremap <silent> <Plug>(MatchitVisualBackward) :call matchit#Match_wrapper('',0,'v')m'gv``
xnoremap <silent> <Plug>(MatchitVisualForward) :call matchit#Match_wrapper('',1,'v'):if col("''") != col("$") | exe ":normal! m'" | endifgv``
nnoremap <silent> <Plug>(MatchitNormalBackward) :call matchit#Match_wrapper('',0,'n')
nnoremap <silent> <Plug>(MatchitNormalForward) :call matchit#Match_wrapper('',1,'n')
nnoremap <silent> <Plug>(startify-open-buffers) :call startify#open_buffers()
nnoremap <Plug>NERDCommenterAltDelims :call nerdcommenter#SwitchToAlternativeDelimiters(1)
xnoremap <silent> <Plug>NERDCommenterUncomment :call nerdcommenter#Comment("x", "Uncomment")
nnoremap <silent> <Plug>NERDCommenterUncomment :call nerdcommenter#Comment("n", "Uncomment")
xnoremap <silent> <Plug>NERDCommenterAlignBoth :call nerdcommenter#Comment("x", "AlignBoth")
nnoremap <silent> <Plug>NERDCommenterAlignBoth :call nerdcommenter#Comment("n", "AlignBoth")
xnoremap <silent> <Plug>NERDCommenterAlignLeft :call nerdcommenter#Comment("x", "AlignLeft")
nnoremap <silent> <Plug>NERDCommenterAlignLeft :call nerdcommenter#Comment("n", "AlignLeft")
nnoremap <silent> <Plug>NERDCommenterAppend :call nerdcommenter#Comment("n", "Append")
xnoremap <silent> <Plug>NERDCommenterYank :call nerdcommenter#Comment("x", "Yank")
nnoremap <silent> <Plug>NERDCommenterYank :call nerdcommenter#Comment("n", "Yank")
xnoremap <silent> <Plug>NERDCommenterSexy :call nerdcommenter#Comment("x", "Sexy")
nnoremap <silent> <Plug>NERDCommenterSexy :call nerdcommenter#Comment("n", "Sexy")
xnoremap <silent> <Plug>NERDCommenterInvert :call nerdcommenter#Comment("x", "Invert")
nnoremap <silent> <Plug>NERDCommenterInvert :call nerdcommenter#Comment("n", "Invert")
nnoremap <silent> <Plug>NERDCommenterToEOL :call nerdcommenter#Comment("n", "ToEOL")
xnoremap <silent> <Plug>NERDCommenterNested :call nerdcommenter#Comment("x", "Nested")
nnoremap <silent> <Plug>NERDCommenterNested :call nerdcommenter#Comment("n", "Nested")
xnoremap <silent> <Plug>NERDCommenterMinimal :call nerdcommenter#Comment("x", "Minimal")
nnoremap <silent> <Plug>NERDCommenterMinimal :call nerdcommenter#Comment("n", "Minimal")
xnoremap <silent> <Plug>NERDCommenterToggle :call nerdcommenter#Comment("x", "Toggle")
nnoremap <silent> <Plug>NERDCommenterToggle :call nerdcommenter#Comment("n", "Toggle")
xnoremap <silent> <Plug>NERDCommenterComment :call nerdcommenter#Comment("x", "Comment")
nnoremap <silent> <Plug>NERDCommenterComment :call nerdcommenter#Comment("n", "Comment")
snoremap <silent> <Del> "_c
snoremap <silent> <BS> "_c
snoremap <silent> <C-Tab> :call UltiSnips#ListSnippets()
nnoremap <M-l> L" move between panes to left/bottom/top/right
nnoremap <M-k> K
nnoremap <M-j> J
nnoremap <M-h> H
vnoremap <M-k> :m '<-2gv=gv" move split panes to left/bottom/top/right
vnoremap <M-j> :m '>+1gv=gv
inoremap <silent> =UltiSnips#ExpandSnippet()
inoremap u
inoremap u
inoremap ii
imap jj
inoremap jk
inoremap kj
abbr ad advertisement
let &cpo=s:cpo_save
unlet s:cpo_save
set background=light
set clipboard=unnamedplus
set expandtab
set helplang=en
set ignorecase
set mouse=a
set runtimepath=~/.config/nvim,~/.local/share/nvim/plugged/vim,~/.local/share/nvim/plugged/vim-devicons,~/.local/share/nvim/plugged/ultisnips,~/.local/share/nvim/plugged/vim-snippets,~/.local/share/nvim/plugged/nvim-cmp,~/.local/share/nvim/plugged/nerdtree,~/.local/share/nvim/plugged/nerdcommenter,~/.local/share/nvim/plugged/vim-startify,~/.local/share/nvim/plugged/cmp-nvim-r,~/.local/share/nvim/plugged/Nvim-R,/etc/xdg/xdg-pop/nvim,/etc/xdg/nvim,~/.local/share/nvim/site,/usr/share/pop/nvim/site,/usr/share/gnome/nvim/site,~/.local/share/flatpak/exports/share/nvim/site,/var/lib/flatpak/exports/share/nvim/site,/usr/local/share/nvim/site,/usr/share/nvim/site,/usr/share/nvim/runtime,/usr/share/nvim/runtime/pack/dist/opt/matchit,/usr/lib/nvim,/usr/share/nvim/site/after,/usr/local/share/nvim/site/after,/var/lib/flatpak/exports/share/nvim/site/after,~/.local/share/flatpak/exports/share/nvim/site/after,/usr/share/gnome/nvim/site/after,/usr/share/pop/nvim/site/after,~/.local/share/nvim/site/after,/etc/xdg/nvim/after,/etc/xdg/xdg-pop/nvim/after,~/.local/share/nvim/plugged/vim/after,~/.local/share/nvim/plugged/ultisnips/after,~/.local/share/nvim/plugged/cmp-nvim-r/after,~/.config/nvim/after
set shiftwidth=5
set shortmess=filnxtToOFI
set showmatch
set softtabstop=4
set splitbelow
set splitright
set tabstop=4
set termguicolors
set wildmode=longest,list
" vim: set ft=vim :