2

I'm trying to copy the text inside curly braces and I need to copy the text plus the curly braces into register 'b'. There is a Vim command that could do this?

Mateen Ulhaq
  • 24,552
  • 19
  • 101
  • 135
  • 2
    `:help text-objests` – dlmeetei Apr 16 '18 at 05:55
  • Possible duplicate of [How to select between brackets (or quotes or ...) in Vim?](https://stackoverflow.com/questions/1061933/how-to-select-between-brackets-or-quotes-or-in-vim) – phd Apr 16 '18 at 15:47

1 Answers1

5

Try it visually first:

va{"by

But you can go faster by doing it non-visually:

"bya{
Mateen Ulhaq
  • 24,552
  • 19
  • 101
  • 135
  • 1
    Detailed explanation: `v : enter visual mode` `a{ : select content and curly braces itself` `"by : yank into register b` – Tommy Nguyen Apr 17 '18 at 03:30