develooper Front page | perl.beginners | Postings from March 2002

creating custom switches in my program?

Thread Previous | Thread Next
M z
March 5, 2002 07:26
creating custom switches in my program?
Message ID:

I was looking into documentation on the getopts
module, but was having some difficulty understanding
how to implement it.

The scope of my problem is quite simple, actually. 
can someone help me create a snippet where if no
argument is specified at the command line, than the
output is written out to the input file, and if an
option is given (say -d) at the comment line, the
program subsequently prompts the user for the
destination to write to?

thanks, I think this is easier than I'm making it out
to be, but I have no experience implementing the
getopts module.

Do You Yahoo!?
Try FREE Yahoo! Mail - the world's greatest free email!

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About