From: David Garamond Date: 2004-11-20T19:57:37+09:00 Subject: several questions on using gems 1. If I write a Ruby library (including a gem package) for others, what is the suggested way of require-ing other library? The gem version first (like in Pickaxe II): begin require 'rubygems' require_gem 'foolib' rescue LoadError require 'foolib' end Or the non-gem version first (like in Rake): begin require 'foolib' rescue LoadError require 'rubygems' require_gem 'foolib' end And what's the rationale for each? 2. Has there been a schedule to include rubygems with official Ruby? I guess it won't be in 1.8.2? (I do know Curt plans to include rubygems in the 1.8.2 Windows installer). 3. When rubygems has been included with every Ruby installation, what will be the standard way of requiring libraries? I hope it will be just: require_gem 'foolib' # or perhaps require, whichever What I wouldn't like is having to think to choose between 'require' or 'require_gem' each time I want to load a library. Or write some kind of wrapper. So I'm guessing (again) that there will be some magic stuffs in 'require' and 'require_gem' to seamlessly choose the right stuffs? Regards, dave