Is there any chance to write the content of the current vim buffer to stdout?
I\'d like to use vim to edit content that was passed via stdin - without the need of a
You can also use pipe.vim. It does use a temporary file, but at least you don't have to worry about it in your own script.
To the second part of your question, you use the -s command line option with vim to remap :w to something else (like :w !tee).
-s
:w
:w !tee