Reputation: 1653
i want to know how to install a specific gem with a certain version in rails app vendor so as not to affect other gems installed in the whole system as the server holds lots of rails project with different gems' specifications
Upvotes: 3
Views: 2057
Reputation: 17735
Just install it as a plugin. So if it's hosted on github, for example:
rails plugin install "path_to_git"
or with Rails < 3
script/plugin install "path_to_git"
But Dan is right, a much better approach is to use rvm and bundler. If you have lots of rails projects as you say, this will save you a TON of version conflict headaches down the road.
Upvotes: 1
Reputation: 9605
The simplest answer is to just use Bundler to manage all your gems. That way, you're protected if the versions installed on the server change.
You can get more information here: http://gembundler.com/
Upvotes: 1