Avatar Edgar González

  • Random
  • Archive
  • RSS

Why rails bundler doesn’t install gems inside a group?

As usual I have several gems in bundler groups called :development and :test.

My Gemfile looks like this.

source 'http://rubygems.org'

gem 'rails', '3.0.3'

gem 'sqlite3-ruby', :require => 'sqlite3'
gem 'paperclip'

gem 'aws-s3'

gem 'rack-cors', :require => 'rack/cors'
gem 'will_paginate', '~> 3.0.beta', :require => 'will_paginate'

group :test, :development do
  gem "rack-test", :path => "vendor/gems/rack-test-0.5.7"
  gem "rspec-rails", "~> 2.4"
  gem "cucumber-rails", ">= 0.3.2"
  gem "capybara", "~> 0.4.1.1"
  gem 'simplecov', '>= 0.3.8', :require => false # Will install simplecov-html as a dependency
end

gem 'rest-client'

Everything worked fine, but some day when I run the bundle install command, these gems were ignored and it only installs the gems that not belongs to any group.

That happens because doing some tests related to production environment (few days ago) I ran:

bundle install --without development

And bundler remembers that I did this and will automatically repeat this for the next time

bundle install #remembers and includes --without development

To clear the “cache” I just run:

bundle install --without nothing

And now bundler installs all the gems

    • #rails3
    • #bundler
    • #rails
    • #gems
    • #gemfile
  • 1 year ago
  • 4
  • Comments
  • Permalink
  • Share
    Tweet

4 Notes/ Hide

  1. edgar posted this

Recent comments

Blog comments powered by Disqus
← Previous • Next →

Portrait/Logo

About

When I'm not spending time with Jessica and my kids, I build web applications. Rails developer, believer of Agile Development and Lean startups. NoSQL enthusiast.
CTO and Lord of the API at Piictu

Me, Elsewhere

  • @edgar on Twitter
  • Facebook Profile
  • edgargonzaleznetve on Youtube
  • egg on Flickr
  • edgar on Foursquare
  • My Skype Info
  • Linkedin Profile
  • edgar on github

Twitter

loading tweets…

  • RSS
  • Random
  • Archive
  • Mobile

Effector Theme by Carlo Franco.

Powered by Tumblr