lib/softwear/library/capistrano.rb in softwear-lib-2.1.2 vs lib/softwear/library/capistrano.rb in softwear-lib-2.1.3

- old
+ new

@@ -74,10 +74,14 @@ run_locally { execute "rsync -av --delete #{local_dir} #{remote_dir}" } if fetch(:asset_sync) with rails_env: fetch(:rails_env) || fetch(:stage) do within(release_path) do - with_rvm(fetch(:task_ruby_version)) { execute :rake, 'assets:sync' } + if respond_to?(:with_rvm) + with_rvm(fetch(:task_ruby_version)) { execute :rake, 'assets:sync' } + else + execute :rake, 'assets:sync' + end end end end end