From 449208367563b5b7e9e06cffc719e2500731ce7c Mon Sep 17 00:00:00 2001 From: Guangxiong Lin Date: Fri, 2 Dec 2022 23:42:36 +0800 Subject: Use vim easymotion again --- .vim/after/plugin/easymotion.vim | 78 ++++++++++++++++++++-------------------- .vim/after/plugin/minpac.vim | 3 +- .vim/after/plugin/stargate.vim | 29 --------------- 3 files changed, 41 insertions(+), 69 deletions(-) delete mode 100644 .vim/after/plugin/stargate.vim (limited to '.vim/after') diff --git a/.vim/after/plugin/easymotion.vim b/.vim/after/plugin/easymotion.vim index cd50666..5b243c5 100644 --- a/.vim/after/plugin/easymotion.vim +++ b/.vim/after/plugin/easymotion.vim @@ -1,38 +1,40 @@ -" let g:EasyMotion_do_mapping = 0 -" let g:EasyMotion_smartcase = 1 -" let g:EasyMotion_smartsign_us = 1 -" " let g:EasyMotion_startofline = 0 -" -" map j (easymotion-j) -" nmap j (easymotion-j) -" -" map k (easymotion-k) -" nmap k (easymotion-k) -" -" map l (easymotion-lineforward) -" nmap l (easymotion-lineforward) -" -" map h (easymotion-linebackward) -" nmap h (easymotion-linebackward) -" -" map (easymotion-bd-jk) -" nmap (easymotion-overwin-line) -" -" map n (easymotion-bd-n) -" nmap n (easymotion-bd-n) -" -" map w (easymotion-bd-w) -" nmap w (easymotion-overwin-w) -" -" map e (easymotion-bd-e) -" nmap e (easymotion-bd-e) -" -" map f (easymotion-bd-f) -" nmap f (easymotion-overwin-f) -" -" map s (easymotion-bd-f2) -" nmap s (easymotion-overwin-f2) -" -" nmap / (easymotion-bd-fn) -" -" nmap ; (easymotion-repeat) +let g:EasyMotion_do_mapping = 0 +let g:EasyMotion_smartcase = 1 +let g:EasyMotion_smartsign_us = 1 +" let g:EasyMotion_startofline = 0 + +map j (easymotion-j) +nmap j (easymotion-j) + +map k (easymotion-k) +nmap k (easymotion-k) + +map l (easymotion-lineforward) +nmap l (easymotion-lineforward) + +map h (easymotion-linebackward) +nmap h (easymotion-linebackward) + +map (easymotion-bd-jk) +nmap (easymotion-overwin-line) + +map n (easymotion-bd-n) +nmap n (easymotion-bd-n) + +map w (easymotion-bd-w) +nmap w (easymotion-overwin-w) + +map e (easymotion-bd-e) +nmap e (easymotion-bd-e) + +map f (easymotion-bd-f) +nmap f (easymotion-overwin-f) + +map s (easymotion-bd-f2) +nmap s (easymotion-overwin-f2) + +nmap / (easymotion-bd-fn) + +nmap ; (easymotion-repeat) + +packadd vim-easymotion diff --git a/.vim/after/plugin/minpac.vim b/.vim/after/plugin/minpac.vim index 0ccfe11..65e429e 100644 --- a/.vim/after/plugin/minpac.vim +++ b/.vim/after/plugin/minpac.vim @@ -30,7 +30,6 @@ function! InitMinpac() abort call minpac#add('https://github.com/rhysd/vim-lsp-ale.git', {'type': 'opt'}) call minpac#add('https://github.com/andymass/vim-matchup.git', {'type': 'start'}) - call minpac#add('https://github.com/monkoose/vim9-stargate.git', {'type': 'opt'}) if has('nvim') call minpac#add('https://github.com/nvim-lua/plenary.nvim', {'type': 'opt'}) @@ -68,7 +67,7 @@ function! InitMinpac() abort call minpac#add('https://github.com/yami-beta/asyncomplete-omni.vim', {'type': 'opt'}) call minpac#add('https://github.com/ludovicchabant/vim-gutentags.git', {'type': 'opt'}) - " call minpac#add('https://github.com/easymotion/vim-easymotion.git') + call minpac#add('https://github.com/easymotion/vim-easymotion.git', {'type': 'opt'}) call minpac#add('https://github.com/airblade/vim-rooter.git') call minpac#add('https://github.com/mbbill/undotree.git') call minpac#add('https://github.com/godlygeek/tabular.git') diff --git a/.vim/after/plugin/stargate.vim b/.vim/after/plugin/stargate.vim deleted file mode 100644 index 51444a5..0000000 --- a/.vim/after/plugin/stargate.vim +++ /dev/null @@ -1,29 +0,0 @@ -if has('nvim') | finish | endif - -let g:stargate_name = 'Master' - -packadd vim9-stargate - -" search two characters -noremap f call stargate#OKvim(2) - -" start of a word -noremap w call stargate#OKvim('\<') - -" for the end of a word -noremap e call stargate#OKvim('\S\>') - -" for the start of a line -noremap l call stargate#OKvim('\_^') - -" for the last character on the line -noremap E call stargate#OKvim('\S\s*$') - -" for the end of a line -noremap $ call stargate#OKvim('$') - -" for any bracket, parentheses or curly bracket -noremap [ call stargate#OKvim('[(){}[\]]') - -" switch window -nnoremap W call stargate#Galaxy() -- cgit v1.2.3