This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Setup.exe: Clairvoyant _and_ Brilliant




> -----Original Message-----
> From: Randall R Schulz [mailto:rrschulz@cris.com] 
> Sent: Sunday, May 05, 2002 9:58 AM
> To: cygwin@cygwin.com
> Subject: Setup.exe: Clairvoyant _and_ Brilliant
> 
> 
> Robert,
> 
> I know this is pretty much a dead horse and I'm sure you're 
> growing tired 
> of these nit-pickings, but...

Actually, I'm very happy to discuss it. It's the arguments based on how
it used to work, and/or the appearance that get me down. I've said all
along that I'm not 100% happy with it as it is, and that patchs to get
the same functionality, with no issues, will be considered :}.
 
> One thing that I think would be nice is if the URL scheme 
> were omitted from 
> the URL-encoded directory name of the download cache 
> directory. The reason 
> I say that is that Setup.exe's cache directory naming scheme 
> would then be 
> compatible with the directory naming and creation behavior of 
> "wget -x".

I didn't realise that wget used the same encoding, but it really isn't
surprising - it's the standard used to encode URL's and parameters for
HTTP requests simply applied again.
 
> I understand that this could potentially create a conflict 
> when a given 
> host supports more than one scheme (hosting both an FTP and 
> HTTP mirror is 
> common, including on the mirror I use, mirrors.rcn.net). On 
> the other hand, 
> there would only be a clash if the directory portion of the 
> mirror's URL 
> were the same for both the HTTP and FTP (and rsync) servers 
> and even then, 
> presumably package files of the same name would be identical. 
> So in fact, 
> it seems there's no real clash, right?

That seems like a reasonable supposition. On that basis, I've no issues
(because if we do get a non-conformant mirror we can always reexamine
this).
 
> If, as I believe, there's no real reason to include the URL 
> scheme in the 
> cache directory name, would you, Robert, consider removing it?

Not at the moment. Here's why:
1) We've a user base just getting used to the new functionality, and
trashing everyones cache would be somewhat annoying :].
2) Internally we use the directory name to recreate the mirror that an
object originally came from. If we remove the URL prefix, setup will
have to guess. So this info would have to be stored somewhere else. (See
ini.cc find_routine for an example use).
3) We have some very simple code at the moment, and having to strip the
URL prefix off at mulitple locations would be a PITA.

However,
1) Pavel's URLParser class will address 3 above, by centralising the URL
management, and would allow for easy flexability.
2) If someone came up with good, solid solutions (not ideas :]) to 1 and
2 above, then I'll revisit this.
3) Irrespective of the above, I will accept a patch to add a command
line option to control this.

BTW: doesn't wget -x allow for including the scheme in the directory
name? It seems that it would run into collisions more often
(http://www.foo.com/index.html is unlikely to match
ftp://www.foo.com/index.html) and would benefit from including the
scheme in it's encoding. As wget is a general purpose tool, it's more
likely to find a behaviour altering parameter and patch useful than
setup.exe.

Rob

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]