Pierre
Pierre

Reputation: 8348

Bundle install mess

I have using RVM on a mac for a rails 3 development.

I wanted to run bundle update newrelic_rpm to upgrade to the new version of the gem.

This was a bad idea: it creates a new folder call newrelic_rpm at the root of my app, and bundle (v 1.0.10) displays proudly

Your bundle is complete! It was installed into ./newrelic_rpm

And now i'm stuck, i cannot update my bundle and it keeps putting all my gems in the newly created folder.

can anyone please help me revert to the initial setup (and get rid of this ./newrelic_rpm folder)?

thanks! p.

Upvotes: 5

Views: 449

Answers (2)

Dylan Markow
Dylan Markow

Reputation: 124419

I'm assuming that you first tried something like bundle install newrelic_rpm, which created the newrelic_rpm folder and told Bundler to start using that folder as the default.

Your .bundle/config file likely contains something like this:

---
BUNDLE_PATH: newreli_rpm
BUNDLE_DISABLE_SHARED_GEMS: "1"

The easiest way to fix this (assuming your Bundler is up to date), is to run this command to install everything back in the main shared system paths:

bundle install --system

Then, bundle update newrelic_rpm should do what you intended (updating the newrelic_rpm gem, rather than updating everything and putting it in newrelic_rpm).

Upvotes: 8

Arsen7
Arsen7

Reputation: 12820

First: make backup. Then try removing '.bundle' directory. Or just see the '.bundle/config' file - I guess there will be something interesting.

Upvotes: 1

Related Questions