From: Kyle Hunter Date: 2008-04-26T01:59:09+09:00 Subject: Re: determing what os is running cb wrote: > I need to execute commands differently based on the underlying > platform. I don't need it down to the patch level or anything like > that -- just basic stuff. > > How do I test whether I'm runnnig on Windows, Linux, or Mac? > > Thanks in advance. > > CB if RUBY_PLATFORM =~ /linux/ then #Linux Stuff elsif RUBY_PLATFORM =~ /mswin32/ then #Windows Stuff end etc. -- Posted via http://www.ruby-forum.com/.