0

Is it possible to run vim filter command(:!) for only one word. Not on whole line as default? Or maybe is it possible to run something like: command (word from file)?

1
  • Are you filtering (:<range>!) or just running a command (:!), and do you want to pass the word as a command argument, or as standard input? Does the command have output, and where do you want the output to go? Commented Feb 19, 2012 at 14:30

1 Answer 1

2

I think you can use the system() function.

Test in Windows

before:

date /t

run command:

:s@date /t@\=system(submatch(0))@

after:

Sun 02/19/2012
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.