blob: 55dd52f4052310a9919dbbc67b86829824ef878a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
;; Hopping in text.
(module config.hop {autoload {: util nvim aniseed.nvim}})
(util.use-config :hop {})
(def- opts {:noremap true :silent true})
(nvim.set_keymap :n :m ":HopChar2<cr>" {:silent true})
(nvim.set_keymap :n :M ":HopWord<cr>" {:silent true})
(nvim.set_keymap :o :f
":lua require'hop'.hint_char1({ direction = require'hop.hint'.HintDirection.AFTER_CURSOR, current_line_only = true })<CR>"
opts)
(nvim.set_keymap :o :F
":lua require'hop'.hint_char1({ direction = require'hop.hint'.HintDirection.BEFORE_CURSOR, current_line_only = true })<CR>"
opts)
(nvim.set_keymap :o :t
":lua require'hop'.hint_char1({ direction = require'hop.hint'.HintDirection.AFTER_CURSOR, current_line_only = true, hint_offset = -1 })<CR>"
opts)
(nvim.set_keymap :o :T
":lua require'hop'.hint_char1({ direction = require'hop.hint'.HintDirection.BEFORE_CURSOR, current_line_only = true, hint_offset = 1 })<CR>"
opts)
|