summaryrefslogtreecommitdiff
path: root/lib/rubygems/remote_fetcher.rb
diff options
context:
space:
mode:
authordrbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-08-05 01:00:01 +0000
committerdrbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-08-05 01:00:01 +0000
commit3434676e9e3c87c39fe4a8c411a041449efc7446 (patch)
tree1dabd9705561ef803bb9f62e6d8e3eaf0618a1cb /lib/rubygems/remote_fetcher.rb
parentd24997cce12d27cec767ca7091a076df1b2319db (diff)
* lib/rubygems: Import RubyGems 1.8.7:
Added missing require for `gem uninstall --format-executable`. The correct name of the executable being uninstalled is now displayed with --format-executable. Fixed `gem unpack uninstalled_gem` default version picker. RubyGems no longer claims a nonexistent gem can be uninstalled. `gem which` no longer claims directories are requirable files. `gem cleanup` continues cleaning up gems if one can't be uninstalled due to permissions. Issue #82. Gem repository directories are no longer created world-writable. Patch by Sakuro OZAWA. [Ruby 1.9 - Bug #4930] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32852 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rubygems/remote_fetcher.rb')
-rw-r--r--lib/rubygems/remote_fetcher.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rubygems/remote_fetcher.rb b/lib/rubygems/remote_fetcher.rb
index ba546ca926..e0d12987f3 100644
--- a/lib/rubygems/remote_fetcher.rb
+++ b/lib/rubygems/remote_fetcher.rb
@@ -85,7 +85,7 @@ class Gem::RemoteFetcher
return if found.empty?
- spec, source_uri = found.first
+ spec, source_uri = found.sort_by { |(s,_)| s.version }.last
download spec, source_uri
end