djberg96
12/2/2004 6:53:00 PM
Austin Ziegler <halostatue@gmail.com> wrote in message news:<9e7db91104120207572417ae4f@mail.gmail.com>...
> On Fri, 3 Dec 2004 00:44:28 +0900, aslak hellesoy
> <aslak.hellesoy@gmail.com> wrote:
> > Can anyone tell me how I can figure out from Ruby what platform I'm
> > running on? My Ruby program needs to know whether it's running on
> > linux, cygwin, windows etc...
>
> RUBY_PLATFORM
>
> It's not perfect, but it's a good guess.
>
> -austin
For more detailed information, there is sys-uname. Available on the
RAA. Yes, it works on Windows, too. :)
Regards,
Dan