Skip to content

Instantly share code, notes, and snippets.

@airicbear
Created February 3, 2020 03:54
Show Gist options
  • Save airicbear/058cfe76ff95f76ba2f3f5a5d263c992 to your computer and use it in GitHub Desktop.
Save airicbear/058cfe76ff95f76ba2f3f5a5d263c992 to your computer and use it in GitHub Desktop.

Replace $$ with \[\] with Vim macros (Evil mode)

You can name the macros whatever you want, I just use a, s, and d because that’s what I’m used to.

Define macro a

q a / \$\$ RET c w \[ ESC q

Define macro s

q s / \$\$ RET c w \] ESC q

Define macro d

q d @ a @ s q

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment