Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sometimes in Vim, I'm typing a command and realise that I could really use Vim's motion commands for navigating the command-line:

  • :s/somthing/else/
  • realise that I misspelled something.
  • Fmae and be done with it.

Of course, trying this would just put Fmae at the end of the command. Is there any way to get (a subset of) the vim commands into the vim command-line? After all, that's what it does.

share|improve this question

1 Answer 1

up vote 4 down vote accepted

When i need to edit a long command in command line, i use q+:

then i see a list of my last commands and i can move with regular vim motions and it's easy to edit.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.