mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/rubygems/*, test/rubygems/*: Update to RubyGems 2.4.4
master (2f6e42e). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48468 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1133596e6b
commit
d35a2bd4df
12 changed files with 29 additions and 35 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
Mon Nov 17 12:54:56 2014 SHIBATA Hiroshi <shibata.hiroshi@gmail.com>
|
||||||
|
|
||||||
|
* lib/rubygems/*, test/rubygems/*: Update to RubyGems 2.4.4
|
||||||
|
master (2f6e42e).
|
||||||
|
|
||||||
Mon Nov 17 06:13:06 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Mon Nov 17 06:13:06 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* proc.c (proc_binding): use the original iseq on a binding from
|
* proc.c (proc_binding): use the original iseq on a binding from
|
||||||
|
|
|
@ -9,7 +9,7 @@ require 'rbconfig'
|
||||||
require 'thread'
|
require 'thread'
|
||||||
|
|
||||||
module Gem
|
module Gem
|
||||||
VERSION = '2.4.3'
|
VERSION = '2.4.4'
|
||||||
end
|
end
|
||||||
|
|
||||||
# Must be first since it unloads the prelude from 1.9.2
|
# Must be first since it unloads the prelude from 1.9.2
|
||||||
|
|
|
@ -146,7 +146,6 @@ prefix or only the files that are requireable.
|
||||||
|
|
||||||
def path_description spec_dirs # :nodoc:
|
def path_description spec_dirs # :nodoc:
|
||||||
if spec_dirs.empty? then
|
if spec_dirs.empty? then
|
||||||
spec_dirs = Gem::Specification.dirs
|
|
||||||
"default gem paths"
|
"default gem paths"
|
||||||
else
|
else
|
||||||
"specified path"
|
"specified path"
|
||||||
|
|
|
@ -84,8 +84,6 @@ command to remove old versions.
|
||||||
end
|
end
|
||||||
|
|
||||||
def execute
|
def execute
|
||||||
hig = {}
|
|
||||||
|
|
||||||
if options[:system] then
|
if options[:system] then
|
||||||
update_rubygems
|
update_rubygems
|
||||||
return
|
return
|
||||||
|
|
|
@ -281,7 +281,7 @@ class Gem::Dependency
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
matches = matches.sort_by { |s| s.sort_obj } # HACK: shouldn't be needed
|
matches.sort_by { |s| s.sort_obj } # HACK: shouldn't be needed
|
||||||
end
|
end
|
||||||
|
|
||||||
##
|
##
|
||||||
|
|
|
@ -235,7 +235,7 @@ class Gem::Indexer
|
||||||
sanitize spec
|
sanitize spec
|
||||||
|
|
||||||
spec
|
spec
|
||||||
rescue SignalException => e
|
rescue SignalException
|
||||||
alert_error "Received signal, exiting"
|
alert_error "Received signal, exiting"
|
||||||
raise
|
raise
|
||||||
rescue Exception => e
|
rescue Exception => e
|
||||||
|
|
|
@ -153,10 +153,10 @@ class Gem::Package::Old < Gem::Package
|
||||||
|
|
||||||
begin
|
begin
|
||||||
@spec = Gem::Specification.from_yaml yaml
|
@spec = Gem::Specification.from_yaml yaml
|
||||||
rescue yaml_error => e
|
rescue yaml_error
|
||||||
raise Gem::Exception, "Failed to parse gem specification out of gem file"
|
raise Gem::Exception, "Failed to parse gem specification out of gem file"
|
||||||
end
|
end
|
||||||
rescue ArgumentError => e
|
rescue ArgumentError
|
||||||
raise Gem::Exception, "Failed to parse gem specification out of gem file"
|
raise Gem::Exception, "Failed to parse gem specification out of gem file"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -326,7 +326,7 @@ class Gem::RemoteFetcher
|
||||||
|
|
||||||
def correct_for_windows_path(path)
|
def correct_for_windows_path(path)
|
||||||
if path[0].chr == '/' && path[1].chr =~ /[a-z]/i && path[2].chr == ':'
|
if path[0].chr == '/' && path[1].chr =~ /[a-z]/i && path[2].chr == ':'
|
||||||
path = path[1..-1]
|
path[1..-1]
|
||||||
else
|
else
|
||||||
path
|
path
|
||||||
end
|
end
|
||||||
|
@ -352,6 +352,10 @@ class Gem::RemoteFetcher
|
||||||
uri.scheme.downcase == 'https'
|
uri.scheme.downcase == 'https'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def close_all
|
||||||
|
@pools.each_value {|pool| pool.close_all}
|
||||||
|
end
|
||||||
|
|
||||||
protected
|
protected
|
||||||
|
|
||||||
# we have our own signing code here to avoid a dependency on the aws-sdk gem
|
# we have our own signing code here to avoid a dependency on the aws-sdk gem
|
||||||
|
|
|
@ -28,6 +28,10 @@ class Gem::Request::ConnectionPools # :nodoc:
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def close_all
|
||||||
|
@pools.each_value {|pool| pool.close_all}
|
||||||
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
||||||
##
|
##
|
||||||
|
@ -69,7 +73,7 @@ class Gem::Request::ConnectionPools # :nodoc:
|
||||||
Gem::UriFormatter.new(proxy_uri.password).unescape,
|
Gem::UriFormatter.new(proxy_uri.password).unescape,
|
||||||
]
|
]
|
||||||
elsif no_proxy? uri.host, no_proxy then
|
elsif no_proxy? uri.host, no_proxy then
|
||||||
net_http_args += [nil, nil]
|
net_http_args + [nil, nil]
|
||||||
else
|
else
|
||||||
net_http_args
|
net_http_args
|
||||||
end
|
end
|
||||||
|
|
|
@ -23,6 +23,15 @@ class Gem::Request::HTTPPool # :nodoc:
|
||||||
@queue.push connection
|
@queue.push connection
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def close_all
|
||||||
|
until @queue.empty?
|
||||||
|
if connection = @queue.pop(true) and connection.started?
|
||||||
|
connection.finish
|
||||||
|
end
|
||||||
|
end
|
||||||
|
@queue.push(nil)
|
||||||
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
||||||
def make_connection
|
def make_connection
|
||||||
|
|
|
@ -318,7 +318,6 @@ class Gem::StreamUI
|
||||||
elsif Gem.win_platform?
|
elsif Gem.win_platform?
|
||||||
def _gets_noecho
|
def _gets_noecho
|
||||||
require "Win32API"
|
require "Win32API"
|
||||||
char = nil
|
|
||||||
password = ''
|
password = ''
|
||||||
|
|
||||||
while char = Win32API.new("crtdll", "_getch", [ ], "L").Call do
|
while char = Win32API.new("crtdll", "_getch", [ ], "L").Call do
|
||||||
|
|
|
@ -77,30 +77,6 @@ gems:
|
||||||
|
|
||||||
DIR = File.expand_path(File.dirname(__FILE__))
|
DIR = File.expand_path(File.dirname(__FILE__))
|
||||||
|
|
||||||
module RemoteFetcherCleanup
|
|
||||||
refine Gem::RemoteFetcher do
|
|
||||||
def close_all
|
|
||||||
@pools.each_value {|pool| pool.close_all}
|
|
||||||
end
|
|
||||||
end
|
|
||||||
refine Gem::Request::ConnectionPools do
|
|
||||||
def close_all
|
|
||||||
@pools.each_value {|pool| pool.close_all}
|
|
||||||
end
|
|
||||||
end
|
|
||||||
refine Gem::Request::HTTPPool do
|
|
||||||
def close_all
|
|
||||||
until @queue.empty?
|
|
||||||
if connection = @queue.pop(true) and connection.started?
|
|
||||||
connection.finish
|
|
||||||
end
|
|
||||||
end
|
|
||||||
@queue.push(nil)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
using RemoteFetcherCleanup
|
|
||||||
|
|
||||||
def setup
|
def setup
|
||||||
@proxies = %w[http_proxy HTTP_PROXY http_proxy_user HTTP_PROXY_USER http_proxy_pass HTTP_PROXY_PASS no_proxy NO_PROXY]
|
@proxies = %w[http_proxy HTTP_PROXY http_proxy_user HTTP_PROXY_USER http_proxy_pass HTTP_PROXY_PASS no_proxy NO_PROXY]
|
||||||
@old_proxies = @proxies.map {|k| ENV[k] }
|
@old_proxies = @proxies.map {|k| ENV[k] }
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue