Given the string "hello.h", I want to obtain <hello.h>.

I have tried vim-surround, but while it seems to be able to surround with matching

  1. { }: cs"{
  2. ( ): cs"(
  3. [ ]: cs"{
  4. XML tags: cs"<mytag>

cs"< does not seem to work (presumably because it would clash with the XML tags).

How could I do this easily?

1 Answer 1


The closing angle bracket works. Do cs">.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.