From: Paul Brannan Date: 2003-11-27T06:40:52+09:00 Subject: Re: raise unless RUBY_VERSION[%r/^\s*\d+\.\d+/o].to_f >= 1.8 On Tue, Nov 25, 2003 at 08:32:14AM +0900, Ara.T.Howard wrote: > any better methods of require a specific version/set of versions? require 'rbconfig' major = Config::CONFIG['MAJOR'].to_i minor = Config::CONFIG['MINOR'].to_i teeny = Config::CONFIG['TEENY'].to_i if major < 1 or (major == 1 and minor < 8) then raise "wrong version" end Of course, this can be wrapped into a nice version class. I wrote one of these a long time ago and never released it, but there are plenty of others already out there. Paul