11

I have a file with several lines like so:

{"latin": "", "french": "", "italian": "", "catalan": "", "portuguese": "", "romanian": "", "spanish": "", "english": ""}

I want to quickly move between the empty quotes to enter data. Is there a short-cut that could be used here?

2 Answers 2

14

f" jumps to the next quote, and F" jumps to the previous one. 3f" jumps three more quotes, and so on. This seems enough to me. If the cursor is inside the quote, and you want to jump to the position just before the ending quote, t" may be used, and similar is said of T". In your case, e (jump to the last character of the current word) and b (jump to the first character of the current word) also do the same thing.

3
  • 8
    Note that ; in normal mode repeats the last fFtT command, allowing for even faster movement.
    – guillem
    Mar 10, 2017 at 7:31
  • 2
    On a similar note , repeats the last search as well, but searches backwards on the line.
    – Octaviour
    Mar 10, 2017 at 15:01
  • Also, both ; and , are commonly remapped (to : and mapleader respectively), so if anyone is using a vimrc copied from the internet the default behaviour may not work.
    – evilsoup
    Mar 11, 2017 at 13:42
3
  • Search for empty quotes: /"";
  • Repeat search with n key;
  • Enter text into empty quotes with a key.

Your Answer

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

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