On 7/25/07, Wes Gamble <weyus / att.net> wrote:
> Under Windows, the gems are not separate from the Ruby installation,
> hence my question.
>
> RUBY_HOME=C:\ruby
>
> Gems live in C:\ruby\lib\ruby\gems.
>
> I plan to just copy them over in the new installation directory for now.

Wes, don't forget that some gems install a binary component which if
you just copy the gem tree, you will miss. I would suggest that you
get all the gems from your gem cache directory. Your cache directory
can be found by:

gem environment <enter>
RubyGems Environment:
  - VERSION: 0.9.2 (0.9.2)
  - INSTALLATION DIRECTORY: /opt/local/lib/ruby/gems/1.8
  - GEM PATH:
     - /opt/local/lib/ruby/gems/1.8
  - REMOTE SOURCES:
     - http://gems.rubyforge.org

The GEM PATH plus cache, so on my system
/opt/local/lib/ruby/gems/1.8/cache is where all the gem files live.
Copy these off and then update your ruby, then (with gem installed if
necessary it is part of the one click installer), in the directory
where you copied off the gems:

gem install *.gem --force

You need the force to simplify the handling of dependencies and
assumedly all the dependencies were valid in your previous install.

Note this can take a while if you have a lot of gems, but this has
worked for me in the past.

Good luck
pth