-
Notifications
You must be signed in to change notification settings - Fork 301
Closed
Description
Got the RuntimeError:
RVM gem is currently unavailable
when creating a new app like so:
rails_apps_composer new name -r core
Not sure if this is something on my end or something internal.
recipe Running extras recipe...
extras Set a robots.txt file to ban spiders? (y/n)
extras Set a robots.txt file to ban spiders? (y/n) y
extras Create a project-specific rvm gemset and .rvmrc? (y/n) y
extras Create a GitHub repository? (y/n) n
extras recipe banning spiders by modifying 'public/robots.txt'
extras recipe creating project-specific rvm gemset and .rvmrc
/var/folders/p3/rnkdqw0x1rsfsv7nvf9y91gc0000gn/T/template20120913-21771-16vdqdm:1652:in `rescue in apply': RVM gem is currently unavailable. (RuntimeError)
from /var/folders/p3/rnkdqw0x1rsfsv7nvf9y91gc0000gn/T/template20120913-21771-16vdqdm:1646:in `apply'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/actions.rb:221:in `instance_eval'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/actions.rb:221:in `apply'
from /.../.rvm/gems/ruby-1.9.3-head/gems/railties-3.2.7/lib/rails/generators/app_base.rb:109:in `apply_rails_template'
from (eval):1:in `apply_rails_template'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/invocation.rb:126:in `block in invoke_all'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/invocation.rb:126:in `each'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/invocation.rb:126:in `map'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/invocation.rb:126:in `invoke_all'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/group.rb:238:in `dispatch'
from /.../.rvm/gems/ruby-1.9.3-head/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
from /.../.rvm/gems/ruby-1.9.3-head/gems/railties-3.2.7/lib/rails/commands/application.rb:38:in `<top (required)>'
from /.../.rvm/rubies/ruby-1.9.3-head/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
from /.../.rvm/rubies/ruby-1.9.3-head/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
from /.../.rvm/gems/ruby-1.9.3-head/gems/railties-3.2.7/lib/rails/cli.rb:15:in `<top (required)>'
from /.../.rvm/rubies/ruby-1.9.3-head/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
from /.../.rvm/rubies/ruby-1.9.3-head/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
from /.../.rvm/gems/ruby-1.9.3-head/gems/railties-3.2.7/bin/rails:7:in `<top (required)>'
from /.../.rvm/gems/ruby-1.9.3-head/bin/rails:19:in `load'
from /.../.rvm/gems/ruby-1.9.3-head/bin/rails:19:in `<main>'
Activity
DanielKehoe commentedon Sep 13, 2012
This is most likely due to an rvm installation problem. First, can you create a new rvm gemset manually? Do you have the newest rvm release?
$ rvm get latest
Try updating your rvm gemgem update rvm
If still seeing a failure, I recommend removing and reinstalling rvm. Let me know how it goes.mmay commentedon Sep 18, 2012
Thanks for the quick reply. Silly me, the problem was that I didn't have the rvm gem in my current gemset.
Closing.
listrophy commentedon Mar 6, 2013
I'm getting the same error. I'm using both the latest stable version of rvm and the latest version of the rvm gem.
Do I need to run
rails_apps_composer
from ruby's global gemset?listrophy commentedon Mar 6, 2013
And if I say no to the rvm question, I still get an rvm-(seemingly-)related error:
listrophy commentedon Mar 6, 2013
Hmmm... I'm getting somewhere now. I'm using bundler to install rails_apps_composer, and it looks like I need to include all the gems I'll need in the Gemfile:
DanielKehoe commentedon Mar 6, 2013
You can install rails_apps_composer into the global gemset, but I recommend creating a gemset for rails_apps_composer:
You'll need to add Rails before running rails_apps_composer:
Installation is simple:
Then try
There is no need to install additional gems as rails_apps_composer will add them to to a temporary application template and Bundler will install them as needed.
I suggest taking a look at the article http://railsapps.github.com/installing-rails.html to make sure your development environment is set up correctly. Not sure why you are seeing the errors.
listrophy commentedon Mar 6, 2013
I'm pretty sure the problem was that I had installed rails_apps_composer via bundler. Bundler was probably isolating rails_apps_composer from other gemsets (or some other such nonsense that is entirely acceptable except in rails_apps_composer's case).
I've got it working now(-ish) by not using bundler to install rails_apps_composer. Would you mind updating the Installation part of the readme to advise against using bundler to install rails_apps_composer? I think it would help others.
DanielKehoe commentedon Mar 6, 2013
I've never used Bundler this way so please help me understand. Did you create a new folder with a Gemfile that includes rails_apps_composer? And then ran
bundle install
to install rails_apps_composer?listrophy commentedon Mar 6, 2013
That's exactly what I did. And it borked everything.
DanielKehoe commentedon Mar 6, 2013
Ok, good to know. I've update the README install instructions to offer a warning.