summaryrefslogtreecommitdiff
path: root/lib/rubygems/installer.rb
diff options
context:
space:
mode:
-rw-r--r--lib/rubygems/installer.rb19
1 files changed, 12 insertions, 7 deletions
@@ -136,8 +136,9 @@ class Gem::Installer
end
##
- # Constructs an Installer instance that will install the gem located at
- # +gem+. +options+ is a Hash with the following keys:
#
# :bin_dir:: Where to put a bin wrapper if needed.
# :development:: Whether or not development dependencies should be installed.
@@ -157,6 +158,7 @@ class Gem::Installer
# :wrappers:: Install wrappers if true, symlinks if false.
# :build_args:: An Array of arguments to pass to the extension builder
# process. If not set, then Gem::Command.build_args is used
def initialize(package, options={})
require 'fileutils'
@@ -471,7 +473,7 @@ class Gem::Installer
unless File.exist? bin_path then
# TODO change this to a more useful warning
- warn "#{bin_path} maybe `gem pristine #{spec.name}` will fix it?"
next
end
@@ -608,7 +610,9 @@ class Gem::Installer
def ensure_required_ruby_version_met # :nodoc:
if rrv = spec.required_ruby_version then
unless rrv.satisfied_by? Gem.ruby_version then
- raise Gem::InstallError, "#{spec.name} requires Ruby version #{rrv}."
end
end
end
@@ -616,8 +620,9 @@ class Gem::Installer
def ensure_required_rubygems_version_met # :nodoc:
if rrgv = spec.required_rubygems_version then
unless rrgv.satisfied_by? Gem.rubygems_version then
- raise Gem::InstallError,
- "#{spec.name} requires RubyGems version #{rrgv}. " +
"Try 'gem update --system' to update RubyGems itself."
end
end
@@ -821,7 +826,7 @@ TEXT
#
# Version and dependency checks are skipped if this install is forced.
#
- # The dependent check will be skipped this install is ignoring dependencies.
def pre_install_checks
verify_gem_home options[:unpack]