Q in normal mode to execute the last recorded macro.
- Use
\{-} as non-greedy regex symbol.
- Use
\_. to match any character including newline (multi-line).
- Use
\Vpattern (very non-magic) to match the pattern literally, only ^ and $ will have special meaning.
- Use
\vpattern (very magic) to match the pattern as a regex.
- Classic negative/positive lookahead/behind (example in very magic):
|
lookbehind |
lookahead |
| positive |
(atom)@<= |
(atom)@= |
| negative |
(atom)@<! |
(atom)@! |
- Use
\L (eg.: s/.*/\L&/) to lowercase the match; use \U (eg.: s/.*/\U&/) to uppercase it.