Class: RubyConfig::Rubygems
- Inherits:
-
Object
- Object
- RubyConfig::Rubygems
- Defined in:
- lib/ruby_config/rubygems.rb
Constant Summary collapse
- VERSION =
"1.3.5"- ARCHIVE_NAME =
"rubygems-#{VERSION}"- ARCHIVE_FILE_NAME =
"#{ARCHIVE_NAME}.tgz"- DOWNLOAD_URL =
"http://rubyforge.org/frs/download.php/60718/#{ARCHIVE_FILE_NAME}"
Instance Method Summary collapse
- #gem_install(gem_technical_name, runtime) ⇒ Object
-
#initialize(ruby_config_path) ⇒ Rubygems
constructor
A new instance of Rubygems.
- #install(runtime) ⇒ Object
Constructor Details
#initialize(ruby_config_path) ⇒ Rubygems
Returns a new instance of Rubygems.
10 11 12 |
# File 'lib/ruby_config/rubygems.rb', line 10 def initialize(ruby_config_path) @ruby_config_path = ruby_config_path end |
Instance Method Details
#gem_install(gem_technical_name, runtime) ⇒ Object
22 23 24 |
# File 'lib/ruby_config/rubygems.rb', line 22 def gem_install(gem_technical_name, runtime) system "#{runtime.gem_executable_path} install -q --no-ri --no-rdoc #{gem_technical_name}" end |
#install(runtime) ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/ruby_config/rubygems.rb', line 14 def install(runtime) download_file(DOWNLOAD_URL, archive_file_name) unless archive_exists? extract_tar_gz(archive_file_name, tmp_path) ruby_gems_setup(archive_path, runtime.ruby_executable_path, runtime.additional_library_path) end |