Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^2: Append to file or create file depending on input filename.

by pKai (Priest)
on Nov 20, 2009 at 13:48 UTC ( [id://808435]=note: print w/replies, xml ) Need Help??


in reply to Re: Append to file or create file depending on input filename.
in thread Append to file or create file depending on input filename.

I was wondering the same.

To (ab)use 2-arg open in the way the OP describes, he has to do some trickery like:

C:\>perl script.pl ">outfile" C:\>rem Or C:\>perl script.pl ^>outfile

which will effectively hide the output redirect from the cmd and result in an $ARGV[0] containing >outfile.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (7)
As of 2024-04-23 21:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found