lib/softwear/lib.rb in softwear-lib-0.0.10 vs lib/softwear/lib.rb in softwear-lib-0.0.11
- old
+ new
@@ -60,18 +60,19 @@
end
end
def self.capistrano(context)
context.instance_eval do
- gem_home = fetch(:gems_path) || "~/.rvm/rubies/#{fetch(:rvm_ruby_string)}/gems/gems"
+ ruby = fetch(:rvm_ruby_string)
+ gem_home = fetch(:gems_path) || "~/.rvm/rubies/#{ruby}/gems/gems"
namespace :deploy do
desc 'Assure softwear-lib is up to date before deploying'
task :update_softwear_lib do
on roles(:app), in: :sequence do
- execute "gem install softwear-lib"
- execute "gem install -i #{gem_home} softwear-lib"
+ execute "(rvm use #{ruby}; gem install softwear-lib)"
+ execute "(rvm use #{ruby}; gem install -i #{gem_home} softwear-lib)"
end
end
before :updating, :update_softwear_lib