2009/12/8 Marcus Meissner <meissner@suse.de>:
On Tue, Dec 08, 2009 at 05:07:54PM +0000, Rob OpenSuSE wrote:
2009/12/8 Jean Delvare <jdelvare@suse.de>:
Out of curiosity, is there a shell command that would simply buffer every input until EOF and then flush everything to stdout?
Would perl script, slurping the whole file into memory, and then flush the contents not work?
Perhaps dd with a very large blocksize.
dd bs=10G
perl -e '$/ = undef; $fin = <STDIN>; print STDOUT $fin' is "obvious", but I got this down to a general filter : perl -p00e "" And you can ensure it reads whole file, by testing at terminal with trad. place holder "-" : ~/bin> perl -p00e "" "date |" - "date |" Tue Dec 8 22:36:01 GMT 2009 1 # typing now 2 3 # going to hit CNTRL-D next line 1 # typing now 2 3 # going to hit CNTRL-D next line Tue Dec 8 22:36:05 GMT 2009 Should only allocate the memory you actually use. Rob -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-packaging+help@opensuse.org