From: Stefan Mahlitz Date: 2005-11-14T16:22:40+09:00 Subject: Re: detect if windows or linux Alexander Fleck wrote: > Hi, > what' s the best way to detect if I' m on a windows or linux machine. I don' t want to check that by handling an exception. Is there a function in the standard libraries. > Thanks, > Alex. There is the constant RUBY_PLATFORM, on my WinXP-box it contains the string 'i386-mswin32', my debian has 'i386-linux'.