Thursday, February 09, 2006

Perl HowTo: determine the Operating system

I tried to figure our the operation system where my Perl script is running.

I found the following URL provides all the necessary info.
http://alma.ch/perl/perloses.htm

To be short, as quoted in the page.

"As of version 5.002, Perl is built with a $^O variable that indicates the operating system it was built on. This was implemented to help speed up code that would otherwise have to use Config; and use the value of $Config{'osname'}. Of course, to get detailed information about the system, looking into %Config is certainly recommended."