This project is archived and is in readonly mode.

#4100 ✓resolved

commit 6f4c451 malfunctions with rvm's gemset

Reported by Sakuro | March 3rd, 2010 @ 04:40 PM | in 3.0.2

[EDIT: format correctly]

This problem happens when you use rvm and install bundler gem in one of
its gemsets(rvm's feature to switch between sets of gems to use) and
generate an application with --dev or --edge option.

Create a gemset dedicated to Rails3(say rails3b) and install bundler in it:

$ rvm use mput-head
$ rmv gemset create rails3b
$ rvm use mput-head%rails3b
$ gem install rails3b ... # installs rails3 dependencies including bundler
$ which bundle

Now rails derives bundle command's path from Thor.ruby_command,
which is ~/.rvm/rubies/mput-head/bin/ruby, it expects bundle command
is ~/.rvm/rubies/mput-head/bin/bundle. So

$ ruby ~/Projects/rails/railties/bin/rails myapp --dev
create  vendor/plugins/.gitkeep
   run  ~/.rvm/rubies/mput-head/bin/bundle install from "."
~/.rvm/gems/mput-head%rails3b/gems/thor-0.13.4/lib/thor/actions.rb:212:in ``':
No such file or directory - ~/.rvm/rubies/mput-head/bin/bundle install (Errno::ENOENT)
  from ~/.rvm/gems/mput-head%rails3b/gems/thor-0.13.4/lib/thor/actions.rb:212:in `run'
  from ~/Projects/rails/railties/lib/generators/rails/app/app_generator.rb:182:in `bundle_if_dev_or_edge'

FYI, rvm prepends some paths to PATH. They are
~/.rvm/rubies/mput-head/bin, ~/.rvm/gems/mput-head%rails3b/bin, ~/.rvm/gems/mput-head%global/bin and ~/.rvm/bin.

Any workaround?

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href=""></a>

Referenced by