lib/rconf/configurators/ruby_configurator.rb in rconf-0.8.1 vs lib/rconf/configurators/ruby_configurator.rb in rconf-0.8.2
- old
+ new
@@ -130,28 +130,26 @@
if out =~ /rvm #{RVM_VERSION.gsub('.', '\\.')}/
report_success
else
report_failure
if out =~ /rvm ([^\s]+)/
- report_fatal "You have rvm #{Regexp.last_match[1]} installed which is not compatible with rconf.\n" +
- "Please uninstall your version of rvm and re-run rconf which will install rvm #{RVM_VERSION}.\n" +
- "You can uninstall rvm by running 'rvm implode' or 'rm -rf ~/.rvm'"
- else
- report_check("Installing rvm #{version}")
- rvm_src = File.join(ENV['HOME'] || '/root', '.rvm/src')
- FileUtils.mkdir_p(rvm_src)
- Dir.chdir(rvm_src) do
- Command.execute('curl', '-O', '-f',
- "#{RVM_RELEASES_URL}/rvm-#{version}.tar.gz",
- :abort_on_failure => "Failed to download rvm #{version}")
- Command.execute('tar', 'zxf', "rvm-#{version}.tar.gz",
- :abort_on_failure => "Failed to extract rvm tgz from #{File.join(Dir.getwd, 'rvm-' + version + '.tar.gz')}")
- end
- Dir.chdir(File.join(rvm_src, "rvm-#{version}")) do
- Command.execute('./install', :abort_on_failure => "Failed to install rvm #{version}")
- end
- report_success
+ report_error "WARNING!: You have rvm #{Regexp.last_match[1]} installed which may not be compatible with rconf.\n" +
+ "rconf will proceed and try to install rvm #{version}."
end
+ report_check("Installing rvm #{version}")
+ rvm_src = File.join(ENV['HOME'] || '/root', '.rvm/src')
+ FileUtils.mkdir_p(rvm_src)
+ Dir.chdir(rvm_src) do
+ Command.execute('curl', '-O', '-f',
+ "#{RVM_RELEASES_URL}/rvm-#{version}.tar.gz",
+ :abort_on_failure => "Failed to download rvm #{version}")
+ Command.execute('tar', 'zxf', "rvm-#{version}.tar.gz",
+ :abort_on_failure => "Failed to extract rvm tgz from #{File.join(Dir.getwd, 'rvm-' + version + '.tar.gz')}")
+ end
+ Dir.chdir(File.join(rvm_src, "rvm-#{version}")) do
+ Command.execute('./install', :abort_on_failure => "Failed to install rvm #{version}")
+ end
+ report_success
end
setup_bashrc
true
end