mirror of
https://github.com/chylex/dotfiles.git
synced 2024-11-25 05:42:47 +01:00
Compare commits
No commits in common. "62edd5222d51413101408499ccf9c1575490c631" and "9fa73b1ba80e282f754dde0e53f5be9636a4bbb8" have entirely different histories.
62edd5222d
...
9fa73b1ba8
@ -136,6 +136,10 @@ nnoremap gp `[v`]
|
||||
xnoremap p P
|
||||
xnoremap P p
|
||||
|
||||
" Extend/shrink selection
|
||||
xmap + <Action>(EditorSelectWord)
|
||||
xmap - <Action>(EditorUnSelectWord)
|
||||
|
||||
" Show parameter info
|
||||
nmap <A-p> <Action>(ParameterInfo)
|
||||
imap <A-p> <Action>(ParameterInfo)
|
||||
|
39
.vimrc
39
.vimrc
@ -125,44 +125,6 @@ nnoremap gp `[v`]
|
||||
xnoremap p P
|
||||
xnoremap P p
|
||||
|
||||
" Clear search highlights
|
||||
nnoremap <Esc> :nohlsearch<Return><Esc>
|
||||
|
||||
" Update search register when using f/t
|
||||
function FindChar(action, reverse)
|
||||
let t:reversesearch = a:reverse
|
||||
let c = nr2char(getchar())
|
||||
call setreg('/', c)
|
||||
nohlsearch
|
||||
execute 'normal! '.a:action.c
|
||||
endfunction
|
||||
|
||||
function FindCharVisual(action, reverse)
|
||||
normal gv
|
||||
call FindChar(a:action, a:reverse)
|
||||
endfunction
|
||||
|
||||
function! ResetReverseSearchFlag()
|
||||
if getcmdtype() =~ "[/?]"
|
||||
let t:reversesearch = 0
|
||||
endif
|
||||
endfunction
|
||||
|
||||
nmap f :call FindChar('f', 0)<CR>
|
||||
nmap F :call FindChar('F', 1)<CR>
|
||||
nmap t :call FindChar('t', 0)<CR>
|
||||
nmap T :call FindChar('T', 1)<CR>
|
||||
|
||||
xmap f :call FindCharVisual('f', 0)<CR>
|
||||
xmap F :call FindCharVisual('F', 1)<CR>
|
||||
xmap t :call FindCharVisual('t', 0)<CR>
|
||||
xmap T :call FindCharVisual('T', 1)<CR>
|
||||
|
||||
noremap <expr> n 'nN'[t:reversesearch]
|
||||
noremap <expr> N 'Nn'[t:reversesearch]
|
||||
|
||||
cnoremap <CR> <cmd>call ResetReverseSearchFlag()<CR><CR>
|
||||
|
||||
" Plugin: https://github.com/easymotion/vim-easymotion.git
|
||||
nmap <Space> <Plug>(easymotion-overwin-f)
|
||||
xmap <Space> <Plug>(easymotion-s)
|
||||
@ -173,3 +135,4 @@ let g:highlightedyank_highlight_duration = 500
|
||||
|
||||
" Plugin: https://github.com/luochen1990/rainbow
|
||||
let g:rainbow_active = 1
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user