Skip to content

Instantly share code, notes, and snippets.

@jeffkreeftmeijer
Last active December 12, 2020 11:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jeffkreeftmeijer/135a2489400d6742b47ef649923abf26 to your computer and use it in GitHub Desktop.
Save jeffkreeftmeijer/135a2489400d6742b47ef649923abf26 to your computer and use it in GitHub Desktop.

Vim Substitutions

History

Regular events

[1] [2]

Regular expressions in QED

[3] [4]

ed(1) and g/re/p

[5]

/ and ?

[6] [7]

n, N, *, #, g*, g#, gd, gD

Regular expressions in Vim

[8] [9]

Magic

[10]

// and ??

[11]

Search offsets

[12]

Substitute

:substitute, :su, :s

[13]

Flags

[14]

Ranges

[15]

:&, :~, &, g&

Expressions in substitutions

[16]

Modern substitutions

Keystrokes and chords

Switching between searching and substituting

[17]


5. man -P 'less -p "^REGULAR EXPRESSIONS"' ed
6. :help /
7. :help ?
8. :help pattern
9. :help usr_27
10. :help magic
11. :help last-pattern
12. :help search-offset
13. :help substitute
14. :help :s_flags
15. :help cmdline-ranges
16. :help sub-replace-special
17. :help incsearch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment