Questions tagged [gemfile]

Gemfile - A format for describing gem dependencies for Ruby programs. A Gemfile describes the gem dependencies required to execute associated Ruby code.

Gemfiles are a format for describing what gems are required by a Ruby program in order to successfully run.

See also

712 questions
22
votes
2 answers

How to add a gem using Bundler

ERROR: paperclip is not part of the bundle. Add it to Gemfile. (Gem::LoadError) to add paperclip gem in bundle list I tried the following: bundle install paperclip but yet again error occurs that is: Your bundle is complete! It was installed…
karnhick
  • 255
  • 1
  • 2
  • 8
20
votes
3 answers

Error running 'bundle install' using Ruby 1.9.3

I'm going through the second edition of Ruby on Rails Tutorial (http://ruby.railstutorial.org/). I'm following each step, so I'm using Ruby 1.9.3 and when I run 'bundle install' inside my Rails project I an error with a big trace of the error which…
Sebastian Sogamoso
  • 333
  • 1
  • 3
  • 9
20
votes
1 answer

Can I force a gem's dependencies in gemfile?

If there are two gems, A and B. A1.0.0 depends on B1.0.0. In my Gemfile: gem 'A', '~> 1.0.0' Then run bundle. It will generate a Gemfile.lock like: A (1.0.0) B (1.0.0) But if I want to force A to use B1.0.1, what's the best practice? Moreover,…
Lai Yu-Hsuan
  • 27,509
  • 28
  • 97
  • 164
20
votes
6 answers

You have already activated rack 1.6.0, but your Gemfile requires rack 1.6.4

Similar to problem with rack 1.3.2. You have already activated rack 1.3.2, but your Gemfile requires rack 1.2.3 -- I'm experiencing You have already activated rack 1.6.0, but your Gemfile requires rack 1.6.4 when attempting to run Rails (4.2) in…
Mark Boulder
  • 13,577
  • 12
  • 48
  • 78
20
votes
2 answers

How to "gem install nokogiri -- --use-system-libraries" via Gemfile

There is a known error installing the latest version of Nokogiri. The workaround is to manually install using gem install nokogiri -- --use-system-libraries But how can this be done via the Gemfile?
s2t2
  • 2,462
  • 5
  • 37
  • 47
19
votes
4 answers

Heroku build fails on uglifier

My minimal app runs locally and I have no bundle errors. When I push to heroku, however, the build fails during assets:precompile step: ... Bundle completed (3.24s) Cleaning up the bundler cache. -----> Preparing app for Rails asset…
vbsql7
  • 684
  • 2
  • 9
  • 17
19
votes
5 answers

Gemfile.lock contains merge conflicts

I just ran git push origin master and got this error after trying to run rails s: Your Gemfile.lock contains merge conflicts. Run `git checkout HEAD -- Gemfile.lock` first to get a clean lock. Neither git checkout HEAD --Gemfile.lock bundle, bundle…
Lauren F
  • 1,282
  • 4
  • 18
  • 29
19
votes
1 answer

The bundle currently has rails locked at 4.0.4

In Gemfile I made the following change: -bash> git diff Gemfile ... -gem 'rails', '4.0.4' +gem 'rails', '4.0.5' I then ran bundle and got a show-stopping message: -bash> bundle Fetching gem metadata from https://rubygems.org/........ Fetching…
user664833
  • 18,397
  • 19
  • 91
  • 140
19
votes
8 answers

Why doesn't "rails s" work from the app directory?

I'm in my app folder, but the command rails s is not working. I read through quite a few posts on Stack Overflow, and most of them seem to be from users who are not in their app directory. In addition, I built a few other apps. I checked those, and…
jmcrist
  • 193
  • 1
  • 1
  • 4
18
votes
1 answer

How to run "bundle exec jekyll new ."

I'm trying to follow "Creating a GitHub Pages site with Jekyll" but when I run any of these commands: $ bundle exec jekyll VERSION new . $ bundle exec jekyll _4.0.0_ new . $ bundle exec jekyll 4.0.0 new . I get this error: "Could not locate Gemfile…
user2901351
  • 629
  • 8
  • 22
17
votes
3 answers

Rails 3.1 Engines: Difference of my_engine.gemspec, add_dependency, add_development_dependency, and Gemfile

Just out of curiosity... in my previous post Rails3.1 engine: can't get SLIM or HAML to work in test/dummy app I asked where to tell Ruby to use some gem in my test/dummy application. The (obvious?) answer was to just put it into the Gemfile of my…
Joshua Muheim
  • 12,617
  • 9
  • 76
  • 152
16
votes
13 answers

Bundle install is not working

I'm developing Ruby on Rails on Windows. Something went wrong with our local network and can't access https://www.rubygems.org, seems like it is blocked or something. But I can access it through http://www.proxyfoxy.com. Below is the result of…
ruby1141
  • 167
  • 1
  • 1
  • 5
15
votes
4 answers

Why does my environment require I run bundle exec?

Whenever I run a rake command (i.e. rake routes) I get this error: You have already activated rake 0.9.2.2, but your Gemfile requires rake 0.9.2. Using bundle exec may solve this. If I run bundle exec rake routes it works. I want to be able to…
vich
  • 11,836
  • 13
  • 49
  • 66
15
votes
3 answers

How do I keep all gems in Gemfile compatible after an update

My question has already been asked here, but I am trying to understand the reasons behind it as opposed to how to work around it. The error I got was; You have already activated rspec-core 2.7.1, but your Gemfile requires rspec-core 2.6.4. Using…
Theo Scholiadis
  • 2,316
  • 2
  • 22
  • 33
15
votes
2 answers

How to specify minimum bundler version for Gemfile?

When my Gemfile is using :mri_20, and previous versions of bundler do not support that, is it a good idea to add gem 'bundler', '~>1.3.5' to the Gemfile? Is there a better way to enforce a minimum bundler version?
Martin
  • 627
  • 4
  • 20
1 2
3
47 48