vim --clean
command! -nargs=? Search {
var needle = escape(<q-args>, '\')
if !empty(needle)
@/ = $'\V{needle}'
normal! n
endif
}
:Search needle
needle
should be searched. Instead command line mode is activated where some input is expected.
As a workaround, exe "normal! n"
works (or not using command block)
command! -nargs=? Search {
var needle = escape(<q-args>, '\')
if !empty(needle)
@/ = $'\V{needle}'
exe "normal! n"
endif
}
9.1.1868
debian13, bash
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.
Related #14491
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.