Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Why is it good practice for a cli script to take switch args before file list?

by leocharre (Priest)
on Jul 19, 2006 at 15:16 UTC ( [id://562315]=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $self = { opt => {}, };
    getopts('f:v:i:a',$self->{opt}); # -f field -v value -i 
        
    # what file(s) did user specify.
    my $files = @ARGV; # only gets fed if arg flags are called via cli bef
    +ore the file list
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (2)
As of 2024-04-26 06:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found