Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Having to remove \r from $ARGV[-1]

by McA (Priest)
on Nov 15, 2012 at 15:24 UTC ( #1004032=note: print w/replies, xml ) Need Help??


in reply to Having to remove \r from $ARGV[-1]

Hi JPMH!

I just wrote the following script for cygwin perl:

use strict; use warnings; use Data::Dumper; print Dumper(\@ARGV);

... and called it with perl a.pl arg1 arg2. I couldn't see a \r at the end of the line. So my guess is: In your shell script where you call the perl script is a extra \r at the end of the line. Look at your editor settings there.

Best regards
McA

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1004032]
help
Chatterbox?
Eily used google. The lazy internet equivalent of grep
[karlgoethebier]: He!
[Eily]: Discipulus pretty much all oneliners are killing. Do you imagine how many people could be working if you asked them to do the same thing in C each time ? :P
Eily is Listening to "Leave out all the rest" by Linkin Park
[karlgoethebier]: that's why trade unions like C ;-)

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (10)
As of 2017-07-21 09:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I came, I saw, I ...
























    Results (320 votes). Check out past polls.