Reputation: 1
my tool is working on rails 3 , but I have old application are running on 2.1.1 (rails 2.1.1 and ruby 1.8.6) and so many libraries are running on old environment(rails 2.1.1 and ruby 1.8.6). I have to send request from new env to old env to generate report . what is best way to approach this scenario? or how to pass rake task to run on old environment from new env?
the report is under lib/abc.rb (on old environment(rails 2.1.1 and ruby 1.8.6)) call this library and dump the yaml into db from new environment (rails 3 and ruby 1.9.2
Upvotes: 0
Views: 120
Reputation: 16619
Does your Rails 2 application use Bundler? If so, try using
bundle exec <your command>
Ex:
bundle exec rake db:migrate
But standard way is to use rvm (http://beginrescueend.com/) to handle multiple ruby versions and get versions. You can do it easily via 'getsets
'.
The following is a quick note I wrote on managing multiple Ruby/gems:
http://keepthingssimple.tumblr.com/post/11274588229/using-rvm-to-keep-things-simple
Upvotes: 1