Ugh.
Once again, I write up another response without completely reading
what you're trying to do.
Instead of determining the OS and then using backticks to execute
shell/OS specific commands, why don't you use OS independent libraries
to manipulate files and directories? Check out File::Co
Gary Yang schrieb:
> Hi All,
>
> I need to port my Perl script from Unix to Windows. Can someone tell me
> how to figure out which platform I am on? i.e. I need to know which Perl
> command can help me determin the platform. Once I know the
> platform, I'll code my script as the example bellow
http://perldoc.perl.org/perlvar.html#$OSNAME
$^O or "use English" and $OSNAME will tell you a little more than what
you're trying to do. What you're trying kind of reminds me of how
Javascript'ers figure out the browser or XHR call they need.
As far as the shebang line (#!...), you're right,
Hi All,
I need to port my Perl script from Unix to Windows. Can someone tell me how
to figure out which platform I am on? i.e. I need to know which Perl command
can help me determin the platform. Once I know the platform, I'll code my
script as the example bellow. But, how to figure out I
4 matches
Mail list logo