Questions tagged [bundler]

Bundler is a tool that makes it easier to keep track of what Ruby gems (and what versions of those gems) an application depends upon. It does so by installing all the gems in your application’s Gemfile. Bundler itself is a gem and can be installed with the following: $ gem install bundler

Bundler is a system that attempts to manage a Ruby application's gem dependencies across multiple developers and environments. One can define the required gems for a Ruby application in a Gemfile and then "bundle" those gems and any sub-dependencies with the application, effectively sandboxing the app -- not just to a specific set of gems, but to a specific set of gem versions.

Useful links

Example Gemfile

source "http://rubygems.org"

gem "capistrano"
gem "haml"
gem "pony", "1.1"
gem "sinatra"
gem "sinatra-content-for2" # content_for :key
gem "unicorn", "1.1.5"

group :development do
  gem "json"
  gem "mechanize"
  gem "nokogiri"
  gem "rack-test"
  gem "rspec"
end
4118 questions
2
votes
1 answer

Is there a node/npm equivalent for Ruby's `bundle open #{gem_name}`?

bundle open #{gem_name} opens a gem you have installed in the application specified by BUNDLER_EDITOR or EDITOR if the former is not present. Obviously it is possible to open the actual location instead, I'm just wondering if node/npm have a similar…
Aaron
  • 13,349
  • 11
  • 66
  • 105
2
votes
2 answers

Bundle Install not working - Rails 4.0

I'm making a simple chat application, and I am using Heroku to temporarily host my application. Thus, I have to use the PostgreSQL gem and Rails_12factor gem. Since I have to put the gem code in the production group in my Gemfile, as I have learned…
Hack Casts
  • 33
  • 6
2
votes
1 answer

Rails not finding gem. "Could not find .. in any of the sources"

I recently set up Ruby on Rails with rbenv. But for some reason I am getting: "Could not find shoulda-matchers-3.1.1 in any of the sources" when I try to do a rails generate scaffold command. Here is my gem environment: RubyGems Environment: -…
Zyaga
  • 43
  • 3
2
votes
3 answers

Where does Bundler install gems pulled from Github?

I want to put a debugger in a file for testing, but can't find where Bundler installs gems pulled from Github on my local machine. I've looked at this thread http://bundler.io/v1.5/git.html which shows how to setup a local file repo to pull from,…
Clay Morton
  • 333
  • 2
  • 15
2
votes
2 answers

How to fix Travis error: NoMethodError: undefined method `spec' for nil:NilClass

This is the error reported by Travis CI when it try to build my gem under Ruby 1.9.3: NoMethodError: undefined method `spec' for nil:NilClass I cannot find any reason or source for this error. This is causing build failures which is misleading…
Keith Bennett
  • 4,722
  • 1
  • 25
  • 35
2
votes
3 answers

Heroku, bundler fails on missing dependencies

I have had trouble recently trying to deploy my rails app on Heroku. In the past, I had deployed apps on Heroku with no problem, but Heroku does not support ruby 2.0.0 anymore. They suggest adding ruby "2.2.4" to the Gemfile, which is what I did.…
2
votes
2 answers

Rails 3's Bundler can create 5 sets of file or folders -- should they be added to the project repo?

I think the 5 sets of files or folder the Rails 3's Bundler create are: Gemfile Gemfile.lock .bundle/config vendor/bundle vendor/cache Is there any more? For each of them, should they be added to the repository? Gemfile and Gemfile.lock, I think…
nonopolarity
  • 146,324
  • 131
  • 460
  • 740
2
votes
1 answer

Whenever gem for Cron job uses incorrect outdated version of bundler

I set up a cron job in my schedule.rb which just executes a custom rake file. Here is my schedule.rb: set :environment , :development every 2.minutes do rake "runpy" , :output => {:error =>…
Aditya Naidu
  • 697
  • 2
  • 7
  • 18
2
votes
2 answers

Best way to add binstub of thor-based utility CLI to Rails app

I have a thor-based CLI that goes with a Rails app, and among the teeming examples of using thor to implement a CLI, I don't find any examples of a simple binstub that would execute in the context of bundler. I want to be able to call my_cli from…
Jim Flood
  • 8,144
  • 3
  • 36
  • 48
2
votes
2 answers

Ruby Could not find mime-types-data-3.2016.0221 in any of the sources (Bundler::GemNotFound)

I'm trying to get Ruby up and running but keep running into this problem. OS: Debian 6 Wheezy Ruby: 2.2.1 Rails: 4.2.6 Create a new project: Rails new Sample1 Get the famous "We're sorry page", error page: Could not find…
user3780225
  • 141
  • 7
2
votes
1 answer

Bundler can't find gem bundler/bower

Environment: Mac OS X 10.11.3 (El Capitan) Homebrew 0.9.5 rvm 1.26.11 (same problem occurs with rbenv) Bundler 1.11.2 Gemfile (excerpt): source 'https://rubygems.org' require 'bundler/bower' asset "jquery", "~2.1.4"` I get this error: bundle…
devkat
  • 1,624
  • 14
  • 15
2
votes
0 answers

Dependencies cache in Wercker

I'm using Wercker on my Ruby on Rails project. My wercker.yml looks like this: box: ruby services: - postgres build: steps: - script: name: Nokogiri fix code: bundle config build.nokogiri --use-system-libraries …
Mateusz Urbański
  • 7,352
  • 15
  • 68
  • 133
2
votes
1 answer

Rails cannot load such file -- openssl (LoadError)

I've got a Rails 4.0.2 app that I'm upgrading to Rails 4.2. I've followed the migration guide exactly. I've run the migration rake task at each step and I also ran bundle / bundle update to update my dependencies. As part of the process I also had…
Daniel Bonnell
  • 4,817
  • 9
  • 48
  • 88
2
votes
1 answer

bundler --without is not excluding gem installation of provided groups

I have the following Gemfile source "http://rubygems.org" gem "bundler", "1.10.6" gem "unicorn", "4.8.2" group :supply do gem "backup", "4.1.10" end group :bunker do gem "capistrano", "3.4.0" gem "capistrano-rbenv", "2.0.3" gem…
bitkot
  • 4,466
  • 2
  • 28
  • 39
2
votes
0 answers

RubyMine not showing gem installed from Github with bundler

RubyMine 7 isn't showing a gem installed from Github with bundler. For example: gem 'spree', '3.0.4' - no conflict, all works gem 'spree', github: 'spree/spree', branch: '~> 3.1.0.beta' - not available in "Ruby SDK and Gems" I've tried adding a…
0xdeface
  • 259
  • 2
  • 11