[Rubygems-developers] Loose end: mirror on Windows

Eric Hodel drbrain at segment7.net
Tue Dec 18 04:01:33 EST 2007

On Dec 17, 2007, at 23:29 PM, Luis Lavena wrote:

> Guys,
> Couldn't check all the ends and pieces of RubyGems on Windows yet (is
> monday, week day) :-P
> Anyway, gem mirror was failing when trying to mirror a file:/// URI,
> which is the test case
> URI.parse is broken for Windows, drive letters are still inside it:
> irb(main):001:0> require 'uri'
> => true
> irb(main):002:0> URI.parse Dir.pwd
> => #<URI::Generic:0x26b4c0a URL:D:/Users/Luis>
> irb(main):003:0> URI.parse "file://#{Dir.pwd}"
> => #<URI::Generic:0x26b338c URL:file://D/Users/Luis>
> irb(main):004:0> URI.parse "file:///#{Dir.pwd}"
> => #<URI::Generic:0x26b1ac8 URL:file:/D:/Users/Luis>
> irb(main):005:0> URI.parse("file:///#{Dir.pwd}").to_s
> => "file:/D:/Users/Luis"
> The included patch check with a regex if get_from contains a drive
> letter (only if scheme is file) and grab the correct part of it.

Please commit, and update the ChangeLog too.

> I need to check the --source option of install, list and others to see
> them working properly.


More information about the Rubygems-developers mailing list