From: Xavier Noria Date: 2007-11-27T03:32:23+09:00 Subject: Re: one-liner for checking platform? On Nov 26, 2007, at 7:20 PM, Giles Bowkett wrote: > Actually, now that I put it that way, I'm going to write one. But does > anyone know the quickest, cleanest way? > > class Kernel > def os_x? > # ??? > end > end Hi Giles, my bet is RUBY_PLATFORM.include?('darwin') That's why include?('win') is not a good test for Windows. -- fxn