Bundle install

What does the command:

bundle install

do?

It seems also that it only works with Rails3?

Thanks.

On 19 Jul 2010, at 18:28, Abder-Rahman A. wrote:

What does the command:

bundle install

do?

It seems also that it only works with Rails3?

First, you need to install the bundler gem

sudo gem install bundler

Then you need to add a Gemfile to your Rails app root folder (the one
with all the folders in app/, lib/ etc).

In the Gemfile, you specify the gems your Rails app uses, for example:

gem “rails”, “2.3.4”
gem “rack”, “1.0.0”

if defined?(JRuby)
gem “activerecord-jdbcmysql-adapter”
gem “sequel” # for FAST import
else # native libraries cannot be compiled on jruby - too bad
gem “mysql”, “2.8.1”
gem “rmagick”, “2.9.1”, :require => ‘pp’ # hack to avoid all the
constant errors before rake spec (env is required twice)
end

group :test do
gem “rspec”, “>=1.2.2”
gem “rspec-rails”, “>=1.2.2”
gem “factory_girl”, “>=1.2.3”
gem “rack-test”
gem “cucumber”, “>=0.6.4”
gem “cucumber-rails”
gem “pickle”
gem “launchy”
gem “database_cleaner”
gem “webrat” unless defined?(JRuby)
gem “selenium-client”
end

group :development do
gem “mongrel”, “>=1.1.5” unless defined?(JRuby)
gem “capistrano”
gem “capistrano_colors”, :require => ‘pp’ # only require when
needed, produces errors on rake spec
end

When you have done so, “bundle install” will install the necessary
gems and the right version and link it into your Rails app.

Thanks a lot Peter for your EXCELLENT support.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs