Just recently, though, I tried uploading my latest code update to PathWrangler, typed 'cap deploy' on the command line, and this got spat back at me:
/Users/[me]/.rvm/lib/rvm/capistrano.rb:5 in `<top (required)>': RVM - Capistrano integration was extracted to a separate gem, install `gem install rvm-capistrano` and remove the `$LOAD_PATH.unshift` line, note also the 'set :rvm_type, :user' is now the default (instead of :system). (RuntimeError)
And following that, a lovely stack trace. Groovy.
A quick bit of Googling reveals this - Ruby Version Manager's discussion on how the integration of RVM functionality into Capistrano has now been moved into its own, separate gem, called 'rvm-capistrano'. Okay, fair enough I think to myself - I shall add that to my Gemfile, and try 'cap deploy' again.
Result:
/Users/[me]/.rvm/lib/rvm/capistrano.rb:5 in `<top (required)>': RVM - Capistrano integration was extracted to a separate gem, install `gem install rvm-capistrano` and remove the `$LOAD_PATH.unshift` line, note also the 'set :rvm_type, :user' is now the default (instead of :system). (RuntimeError)
The same error again. Huh?
A bit of fiddling around reveals the problem - in my config/deploy.rb file, the hub of all Capistrano activity in a Rails app, you of course have 'require "rvm/capistrano"', to import RVM's Capistrano functionality. When the command-line error message says "remove the `$LOAD_PATH.unshift` line", it's trying to tell you that because the RVM-Capistrano stuff is now in its own gem, you no longer need to write 'require "rvm/capistrano". Delete it, and all will be well.
Thanks so much! I've been having the same problem and you led me down the golden path. Whew!
ReplyDeleteThis was very helpful. Thanks!
ReplyDelete