I know not everyone likes using vim but I thought those who do could share a good reason to get into it. For me its the repetition of the last change with the push of the dot key. Replace the current word with another and move the cursor to the next word you wish to replace. It makes the editor so versatile and feels very satisfying.

  • @mekkagodzilla
    link
    English
    61 year ago

    I use vim macros all the time. For example, you have a bunch of lines that need the same 3 operations done:

    • insert " at the beginning of the line
    • insert ", at the end on the line
    • indent

    Press qa, do what you need to do on one line and go one line below, press q again to stop recording the macro, then you can do it 50 times with 50@a.

    • Valen
      link
      English
      31 year ago

      I’ve done this a lot too. It’s the kind of thing where someone watching says “what is this black magic and how do I got to make the text said what I want?”.