Regenerate nvim config
This commit is contained in:
@ -0,0 +1,60 @@
|
||||
" The vim operator plugin to do well with 'sandwich' like structure
|
||||
" Last Change: 31-Oct-2021.
|
||||
" Maintainer : Masaaki Nakamura <mckn@outlook.jp>
|
||||
|
||||
" License : NYSL
|
||||
" Japanese <http://www.kmonos.net/nysl/>
|
||||
" English (Unofficial) <http://www.kmonos.net/nysl/index.en.html>
|
||||
|
||||
if &compatible || exists("g:loaded_operator_sandwich")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_operator_sandwich = 1
|
||||
|
||||
" keymappings
|
||||
nmap <silent> <Plug>(operator-sandwich-add) <Plug>(operator-sandwich-add-pre)<Plug>(operator-sandwich-g@)
|
||||
xmap <silent> <Plug>(operator-sandwich-add) <Plug>(operator-sandwich-add-pre)<Plug>(operator-sandwich-gv)<Plug>(operator-sandwich-g@)
|
||||
omap <silent> <Plug>(operator-sandwich-add) <Plug>(operator-sandwich-g@)
|
||||
nmap <silent> <Plug>(operator-sandwich-delete) <Plug>(operator-sandwich-delete-pre)<Plug>(operator-sandwich-g@)
|
||||
xmap <silent> <Plug>(operator-sandwich-delete) <Plug>(operator-sandwich-delete-pre)<Plug>(operator-sandwich-gv)<Plug>(operator-sandwich-g@)
|
||||
omap <silent> <Plug>(operator-sandwich-delete) <Plug>(operator-sandwich-g@)
|
||||
nmap <silent> <Plug>(operator-sandwich-replace) <Plug>(operator-sandwich-replace-pre)<Plug>(operator-sandwich-g@)
|
||||
xmap <silent> <Plug>(operator-sandwich-replace) <Plug>(operator-sandwich-replace-pre)<Plug>(operator-sandwich-gv)<Plug>(operator-sandwich-g@)
|
||||
omap <silent> <Plug>(operator-sandwich-replace) <Plug>(operator-sandwich-g@)
|
||||
|
||||
nnoremap <silent> <Plug>(operator-sandwich-add-pre) :<C-u>call operator#sandwich#prerequisite('add', 'n')<CR>
|
||||
xnoremap <silent> <Plug>(operator-sandwich-add-pre) <Esc>:call operator#sandwich#prerequisite('add', 'x')<CR>
|
||||
nnoremap <silent> <Plug>(operator-sandwich-delete-pre) :<C-u>call operator#sandwich#prerequisite('delete', 'n')<CR>
|
||||
xnoremap <silent> <Plug>(operator-sandwich-delete-pre) <Esc>:call operator#sandwich#prerequisite('delete', 'x')<CR>
|
||||
nnoremap <silent> <Plug>(operator-sandwich-replace-pre) :<C-u>call operator#sandwich#prerequisite('replace', 'n')<CR>
|
||||
xnoremap <silent> <Plug>(operator-sandwich-replace-pre) <Esc>:call operator#sandwich#prerequisite('replace', 'x')<CR>
|
||||
|
||||
nnoremap <silent> <Plug>(operator-sandwich-add-query1st) :<C-u>call operator#sandwich#query1st('add', 'n')<CR>
|
||||
xnoremap <silent> <Plug>(operator-sandwich-add-query1st) <Esc>:call operator#sandwich#query1st('add', 'x')<CR>
|
||||
nnoremap <silent> <Plug>(operator-sandwich-replace-query1st) :<C-u>call operator#sandwich#query1st('replace', 'n')<CR>
|
||||
xnoremap <silent> <Plug>(operator-sandwich-replace-query1st) <Esc>:call operator#sandwich#query1st('replace', 'x')<CR>
|
||||
|
||||
" supplementary keymappings
|
||||
onoremap <expr><silent> <Plug>(operator-sandwich-synchro-count) operator#sandwich#synchro_count()
|
||||
onoremap <expr><silent> <Plug>(operator-sandwich-release-count) operator#sandwich#release_count()
|
||||
onoremap <expr><silent> <Plug>(operator-sandwich-squash-count) operator#sandwich#squash_count()
|
||||
nnoremap <expr><silent> <Plug>(operator-sandwich-predot) operator#sandwich#predot()
|
||||
nnoremap <expr><silent> <Plug>(operator-sandwich-dot) operator#sandwich#dot()
|
||||
|
||||
" visualrepeat.vim (vimscript #3848) support
|
||||
noremap <silent> <Plug>(operator-sandwich-add-visualrepeat) :<C-u>call operator#sandwich#visualrepeat('add')<CR>
|
||||
noremap <silent> <Plug>(operator-sandwich-delete-visualrepeat) :<C-u>call operator#sandwich#visualrepeat('delete')<CR>
|
||||
noremap <silent> <Plug>(operator-sandwich-replace-visualrepeat) :<C-u>call operator#sandwich#visualrepeat('replace')<CR>
|
||||
|
||||
" intrinsic keymappings
|
||||
noremap <Plug>(operator-sandwich-g@) g@
|
||||
inoremap <Plug>(operator-sandwich-g@) <C-o>g@
|
||||
nnoremap <Plug>(operator-sandwich-gv) gv
|
||||
inoremap <Plug>(operator-sandwich-gv) <C-o>gv
|
||||
|
||||
" use of vim-event-DotCommandPre
|
||||
if !hasmapto('<Plug>(operator-sandwich-predot)') && !hasmapto('<Plug>(operator-sandwich-dot)') && (hasmapto('<Plug>(event-DotCommandPre)') || hasmapto('<Plug>(event-DotCommandPre+Dot)'))
|
||||
augroup sandwich-predot
|
||||
autocmd User DotCommandPre call operator#sandwich#predot()
|
||||
augroup END
|
||||
endif
|
||||
@ -0,0 +1,75 @@
|
||||
" The set of operator/textobj plugins to do well with 'sandwich' like structure
|
||||
" Last Change: 18-Jan-2022.
|
||||
" Maintainer : Masaaki Nakamura <mckn@outlook.jp>
|
||||
|
||||
" License : NYSL
|
||||
" Japanese <http://www.kmonos.net/nysl/>
|
||||
" English (Unofficial) <http://www.kmonos.net/nysl/index.en.html>
|
||||
|
||||
if &compatible || exists("g:loaded_sandwich")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_sandwich = 1
|
||||
|
||||
" intrinsic keymappings
|
||||
onoremap <silent> <Plug>(textobj-sandwich-function-ip) :<C-u>call sandwich#magicchar#f#ip('o')<CR>
|
||||
onoremap <silent> <Plug>(textobj-sandwich-function-i) :<C-u>call sandwich#magicchar#f#i('o')<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-function-ip) :<C-u>call sandwich#magicchar#f#ip('x')<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-function-i) :<C-u>call sandwich#magicchar#f#i('x')<CR>
|
||||
onoremap <silent> <Plug>(textobj-sandwich-function-ap) :<C-u>call sandwich#magicchar#f#ap('o')<CR>
|
||||
onoremap <silent> <Plug>(textobj-sandwich-function-a) :<C-u>call sandwich#magicchar#f#a('o')<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-function-ap) :<C-u>call sandwich#magicchar#f#ap('x')<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-function-a) :<C-u>call sandwich#magicchar#f#a('x')<CR>
|
||||
onoremap <silent> <Plug>(textobj-sandwich-tagname-i) :<C-u>call sandwich#magicchar#t#i()<CR>
|
||||
onoremap <silent> <Plug>(textobj-sandwich-tagname-a) :<C-u>call sandwich#magicchar#t#a()<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-tagname-i) :<C-u>call sandwich#magicchar#t#i()<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-tagname-a) :<C-u>call sandwich#magicchar#t#a()<CR>
|
||||
onoremap <silent> <Plug>(textobj-sandwich-tag-i) :<C-u>call sandwich#magicchar#t#it()<CR>
|
||||
onoremap <silent> <Plug>(textobj-sandwich-tag-a) :<C-u>call sandwich#magicchar#t#at()<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-tag-i) :<C-u>call sandwich#magicchar#t#it()<CR>
|
||||
xnoremap <silent> <Plug>(textobj-sandwich-tag-a) :<C-u>call sandwich#magicchar#t#at()<CR>
|
||||
|
||||
nmap <silent> <Plug>(sandwich-add) <Plug>(operator-sandwich-add)
|
||||
xmap <silent> <Plug>(sandwich-add) <Plug>(operator-sandwich-add)
|
||||
omap <silent> <Plug>(sandwich-add) <Plug>(operator-sandwich-add)
|
||||
nmap <silent> <Plug>(sandwich-delete) <Plug>(operator-sandwich-delete)<Plug>(operator-sandwich-release-count)<Plug>(textobj-sandwich-query-a)
|
||||
xmap <silent> <Plug>(sandwich-delete) <Plug>(operator-sandwich-delete)
|
||||
nmap <silent> <Plug>(sandwich-replace) <Plug>(operator-sandwich-replace)<Plug>(operator-sandwich-release-count)<Plug>(textobj-sandwich-query-a)
|
||||
xmap <silent> <Plug>(sandwich-replace) <Plug>(operator-sandwich-replace)
|
||||
nmap <silent> <Plug>(sandwich-delete-auto) <Plug>(operator-sandwich-delete)<Plug>(operator-sandwich-release-count)<Plug>(textobj-sandwich-auto-a)
|
||||
nmap <silent> <Plug>(sandwich-replace-auto) <Plug>(operator-sandwich-replace)<Plug>(operator-sandwich-release-count)<Plug>(textobj-sandwich-auto-a)
|
||||
|
||||
""" default keymappings
|
||||
" If g:sandwich_no_default_key_mappings has been defined, then quit immediately.
|
||||
if exists('g:sandwich_no_default_key_mappings') | finish | endif
|
||||
|
||||
if !exists('g:operator_sandwich_no_default_key_mappings')
|
||||
" add
|
||||
silent! nmap <unique> sa <Plug>(sandwich-add)
|
||||
silent! xmap <unique> sa <Plug>(sandwich-add)
|
||||
silent! omap <unique> sa <Plug>(sandwich-add)
|
||||
|
||||
" delete
|
||||
silent! nmap <unique> sd <Plug>(sandwich-delete)
|
||||
silent! xmap <unique> sd <Plug>(sandwich-delete)
|
||||
silent! nmap <unique> sdb <Plug>(sandwich-delete-auto)
|
||||
|
||||
" replace
|
||||
silent! nmap <unique> sr <Plug>(sandwich-replace)
|
||||
silent! xmap <unique> sr <Plug>(sandwich-replace)
|
||||
silent! nmap <unique> srb <Plug>(sandwich-replace-auto)
|
||||
endif
|
||||
|
||||
if !exists('g:textobj_sandwich_no_default_key_mappings')
|
||||
" auto
|
||||
silent! omap <unique> ib <Plug>(textobj-sandwich-auto-i)
|
||||
silent! xmap <unique> ib <Plug>(textobj-sandwich-auto-i)
|
||||
silent! omap <unique> ab <Plug>(textobj-sandwich-auto-a)
|
||||
silent! xmap <unique> ab <Plug>(textobj-sandwich-auto-a)
|
||||
|
||||
" query
|
||||
silent! omap <unique> is <Plug>(textobj-sandwich-query-i)
|
||||
silent! xmap <unique> is <Plug>(textobj-sandwich-query-i)
|
||||
silent! omap <unique> as <Plug>(textobj-sandwich-query-a)
|
||||
silent! xmap <unique> as <Plug>(textobj-sandwich-query-a)
|
||||
endif
|
||||
@ -0,0 +1,33 @@
|
||||
" The vim textobject plugin to search and select 'sandwich' like structure
|
||||
" Last Change: 30-Oct-2021.
|
||||
" Maintainer : Masaaki Nakamura <mckn@outlook.jp>
|
||||
|
||||
" License : NYSL
|
||||
" Japanese <http://www.kmonos.net/nysl/>
|
||||
" English (Unofficial) <http://www.kmonos.net/nysl/index.en.html>
|
||||
|
||||
if exists("g:loaded_textobj_sandwich")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_textobj_sandwich = 1
|
||||
|
||||
nnoremap <silent><expr> <Plug>(textobj-sandwich-auto-i) textobj#sandwich#auto('n', 'i')
|
||||
onoremap <silent><expr> <Plug>(textobj-sandwich-auto-i) textobj#sandwich#auto('o', 'i')
|
||||
xnoremap <silent><expr> <Plug>(textobj-sandwich-auto-i) textobj#sandwich#auto('x', 'i')
|
||||
nnoremap <silent><expr> <Plug>(textobj-sandwich-auto-a) textobj#sandwich#auto('n', 'a')
|
||||
onoremap <silent><expr> <Plug>(textobj-sandwich-auto-a) textobj#sandwich#auto('o', 'a')
|
||||
xnoremap <silent><expr> <Plug>(textobj-sandwich-auto-a) textobj#sandwich#auto('x', 'a')
|
||||
|
||||
nnoremap <silent><expr> <Plug>(textobj-sandwich-query-i) textobj#sandwich#query('n', 'i')
|
||||
onoremap <silent><expr> <Plug>(textobj-sandwich-query-i) textobj#sandwich#query('o', 'i')
|
||||
xnoremap <silent><expr> <Plug>(textobj-sandwich-query-i) textobj#sandwich#query('x', 'i')
|
||||
nnoremap <silent><expr> <Plug>(textobj-sandwich-query-a) textobj#sandwich#query('n', 'a')
|
||||
onoremap <silent><expr> <Plug>(textobj-sandwich-query-a) textobj#sandwich#query('o', 'a')
|
||||
xnoremap <silent><expr> <Plug>(textobj-sandwich-query-a) textobj#sandwich#query('x', 'a')
|
||||
|
||||
nnoremap <silent><expr> <Plug>(textobj-sandwich-literal-query-i) textobj#sandwich#query('n', 'i', {}, [])
|
||||
onoremap <silent><expr> <Plug>(textobj-sandwich-literal-query-i) textobj#sandwich#query('o', 'i', {}, [])
|
||||
xnoremap <silent><expr> <Plug>(textobj-sandwich-literal-query-i) textobj#sandwich#query('x', 'i', {}, [])
|
||||
nnoremap <silent><expr> <Plug>(textobj-sandwich-literal-query-a) textobj#sandwich#query('n', 'a', {}, [])
|
||||
onoremap <silent><expr> <Plug>(textobj-sandwich-literal-query-a) textobj#sandwich#query('o', 'a', {}, [])
|
||||
xnoremap <silent><expr> <Plug>(textobj-sandwich-literal-query-a) textobj#sandwich#query('x', 'a', {}, [])
|
||||
Reference in New Issue
Block a user