According to the opening part of
perlrun, this should work on the command line:
echo "print qq(Hello.\n)" | perl
That is, that should be equivalent to the plain ol'
perl -e "print qq(Hello.\n)". And it does
work, on Linux and on Win32 via Cygwin's bash shell. But it doesn't seem to work with the standard Win32 cmd.exe shell. This wouldn't be too surprising, except that I'm surprised that I'm not finding this documented anywhere (Camel, perldocs, here, Activestate, etc.). The closest I can find is
this, which implies that piping is only a problem when running files that have associations.
Am I doing something wrong, or overlooking some documentation? And is this simply not going to work with cmd.exe?
(Incidentally, the motivation for this is to be able to use find2perl on Win32.)
-- Frag.
--
"Just remember what ol' Jack Burton does when the earth quakes, the poison arrows fall from the sky, and the pillars of Heaven shake. Yeah, Jack Burton just looks that big old storm right in the eye and says, "Give me your best shot. I can take it."