Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

command line arg help

by Anonymous Monk
on Nov 04, 2001 at 00:56 UTC ( [id://123078]=perlquestion: print w/replies, xml ) Need Help??

Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re: command line arg help
by mkmcconn (Chaplain) on Nov 04, 2001 at 03:16 UTC
    Try:
    $ who | myprog -r -

    update
    Actually, I shouldn't let this go without recommending that you try Getopt.
    And it may be that you meant to write something like:

    elsif ($ARGV[0] =~ m/^-r$/){ $option = shift @ARGV; &doit($_) for <STDIN>; }
    ... but I wasn't sure that's what you meant.
    No endorsement of this method implied.
    mkmcconn

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://123078]
Approved by root
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (4)
As of 2024-03-29 12:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found