Pathologically Eclectic Rubbish Lister | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Note how the script was called:
By adding the dot slash before the script name, you're telling the shell to open that script and figure out from the shebang line which program to execute it with. Thus, it is not Perl complaining about syntax issues as Perl is never found. The "no such file or directory" is due to the \r at the end of the shebang. Running cat -vE scriptname.pl will show those extra newlines as a cntl-M:
Without the warnings switch, the shebang would look like this:
The shell thinks the cntl-M is part of the filename, thus giving you the 'no such file' error. Cheers, Join the Perlmonks Setiathome Group or just click on the the link and check out our stats. In reply to (Ovid) Re: Re: Odd -w behavior on scripts written on Win32 platform
by Ovid
|
|