In article <[EMAIL PROTECTED]>, Jeff Westman wrote: > Could someone help me please? > > I am trying to write a simple script that will take input from the command > line as well as input from a pipe. > > For example, the script should be able to do both of the following: > > $ cat someFile | myPerlScript.pl # from a pipe [...]
I think this Q was just post here. What about (using diamond '<>')... #!/usr/bin/perl use warnings; use strict; print "Reading from ", $ARGV[0] || "a pipe", ":\n"; while (<>) { print $_; } -- Kevin Pfeiffer International University Bremen -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]