Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

3
  • 3
    Be aware, !$ only expands to the last argument, not all. And this does not answer your question as stated—do you want command substitution as in vim "$(locate foo.txt)"?
    – slhck
    Commented Jul 17, 2013 at 18:19
  • Thanks for pointing that out. Since there are no answers yet, I am going to clarify the question.
    – spuder
    Commented Jul 17, 2013 at 18:25
  • 3
    To take all the parameters, use !* -- gnu.org/software/bash/manual/bashref.html#History-Interaction Commented Jul 17, 2013 at 18:31