How do I move the cursor to the next/previous number?
Ctrl-x and Ctrl-a can't be used since I have :set nrformats+=alpha
.
Vi and Vim Stack Exchange is a question and answer site for people using the vi and Vim families of text editors. It only takes a minute to sign up.
Sign up to join this communityNext number: /[0-9]
or /\d
Previous number: ?[0-9]
or ?\d
For non-decimal numbers, you can also use these equivalences:
\d : [0-9] -> decimal digit
\x : [0-9A-Fa-f] -> hex digit
\o : [0-7] -> octal digit
/[[:digit:]]
and ?[[:digit:]]