Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: $ variables in command line

by erikharrison (Deacon)
on Jun 26, 2002 at 21:05 UTC ( [id://177532]=note: print w/replies, xml ) Need Help??


in reply to $ variables in command line

Following regexes will overwrite previously set $1 and friends. Probably your best best would be to tell users that matches aren't stored in $1, $2 etcetera but in an array named @match. Then, after each user defined regex set @match to the values. This will allow them to be persistent (to a degree, based on how many regexes are fed to your script). This can be a bit confusing if there are a lot of usedefined regexes, because your users might wants a greater degree of persistance that one regex. Of course, if that happens, then you probably need a different solution that command line args.

Cheers,
Erik

Light a man a fire, he's warm for a day. Catch a man on fire, and he's warm for the rest of his life. - Terry Pratchet

Log In?
Username:
Password:

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

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

    No recent polls found