Hello everyone.  Anyone run into this problem?

I have an rails app which is running rails 2.2.2 with rubygems 1.2.0
on a dev box.  Rails is frozen and in SVN.  The hosting server is
running gems 0.9 which appears to be incompatible with rails 2.x.  Is
there a way to freeze rubygems (aka, gem) into a rails project so I do
not impact other's applications?

What I have done (using 1.3.1 as a test case):

wget http://rubyforge.org/frs/download.php/45905/rubygems-1.3.1.tgz
tar zxvf rubygems-1.3.1.tgz
mv rubygems-1.3.1/lib <project>lib/rubygems
cd <project>
svn add lib/rubygems
svn ci -m 'added libraries'
rake deploy (to push app into production)

The idea was I would place the lib/rubygems directory ahead of
everything in the load path...

edit config/environment.rb
# Add additional load paths for your own custom dirs
config.load_paths.insert(0, %W( #{RAILS_ROOT}/lib/rubygems/lib ).to_s)

on the dev box this looks correct (./script/about):

About your application's environment
Ruby version              1.8.7 (i486-linux)
RubyGems version          1.3.1
Rails version             2.2.2
Active Record version     2.2.2
Action Pack version       2.2.2
Active Resource version   2.2.2
Action Mailer version     2.2.2
Active Support version    2.2.2

On production it still is using the older version.:
./script/about
./script/../config/../vendor/rails/railties/lib/initializer.rb:214:in
`install_gem_spec_stubs': undefined method `loaded_specs' for
Gem:Module (NoMethodError)

It appears to still load 0.9.6 on the way.

Regards,

Josh Richard

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to