diff options
| author | jdhao <jdhao@hotmail.com> | 2021-10-18 22:53:22 +0800 |
|---|---|---|
| committer | jdhao <jdhao@hotmail.com> | 2021-10-18 22:53:22 +0800 |
| commit | 71040c76c686c1e993bae1f0c7a4d69c36d4d172 (patch) | |
| tree | 2ecf402554c15d110a1a6379d96dc60418a35620 | |
| parent | 66be7b937999ea462207e5f48a9a27caaf0c740a (diff) | |
replace vim-sneak with hop.nvim
| -rw-r--r-- | core/plugins.vim | 15 | ||||
| -rw-r--r-- | lua/config/nvim_hop.lua | 3 | ||||
| -rw-r--r-- | lua/plugins.lua | 5 |
3 files changed, 5 insertions, 18 deletions
diff --git a/core/plugins.vim b/core/plugins.vim index 111b8fe..07515d9 100644 --- a/core/plugins.vim +++ b/core/plugins.vim @@ -48,21 +48,6 @@ command! -nargs=0 StartVlime call jobstart(printf("sbcl --load %s/vlime/lisp/sta "}} "{{ Search related -"""""""""""""""""""""""""""""vim-sneak settings""""""""""""""""""""""" -" Use sneak label mode -let g:sneak#label = 1 - -nmap f <Plug>Sneak_s -xmap f <Plug>Sneak_s -onoremap <silent> f :call sneak#wrap(v:operator, 2, 0, 1, 1)<CR> -nmap F <Plug>Sneak_S -xmap F <Plug>Sneak_S -onoremap <silent> F :call sneak#wrap(v:operator, 2, 1, 1, 1)<CR> - -" Immediately after entering sneak mode, you can press f and F to go to next -" or previous match -let g:sneak#s_next = 1 - """"""""""""""""""""""""""""" settings for nvim-hlslens""""""""""""""" noremap <silent> n <Cmd>execute('normal! ' . v:count1 . 'nzzzv')<CR> \<Cmd>lua require('hlslens').start()<CR> diff --git a/lua/config/nvim_hop.lua b/lua/config/nvim_hop.lua new file mode 100644 index 0000000..1a29126 --- /dev/null +++ b/lua/config/nvim_hop.lua @@ -0,0 +1,3 @@ +require('hop').setup() + +vim.api.nvim_set_keymap('n', 'f', "<cmd>lua require'hop'.hint_char2()<cr>", {noremap = true}) diff --git a/lua/plugins.lua b/lua/plugins.lua index a2dcd3d..b646632 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -61,9 +61,8 @@ require("packer").startup({ use({ "vlime/vlime", rtp = "vim/", ft = { "lisp" } }) end - -- Super fast movement with vim-sneak - use({"justinmk/vim-sneak", event = "VimEnter"}) - use { 'phaazon/hop.nvim', event = "VimEnter", config = [[require('hop').setup()]] } + -- Super fast buffer jump + use { 'phaazon/hop.nvim', event = "VimEnter", config = [[require('config.nvim_hop')]] } -- Clear highlight search automatically for you use({"romainl/vim-cool", event = "VimEnter"}) |
