-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Tony Lewis wrote:
> Hrvoje Niksic wrote:
> 
>>> And how is .tar.gz renamed?  .tar-1.gz?
>> Ouch.
> 
> OK. I'm responding to the chain and not Hrvoje's expression of pain. :-)
> 
> What if we changed the semantics of --no-clobber so the user could specify
> the behavior? I'm thinking it could accept the following strings:
> - after: append a number after the file name (current behavior)
> - before: insert a number before the suffix
> - new: change name of new file (current behavior)
> - old: change name of old file
> 
> With this scheme --no-clobber becomes equivalent to --no-clobber=after,new.
> If I want to change where the number appears in the file name or have the
> old file renamed then I can specify the behavior I want on the command line
> (or in .wgetrc). I think I would change my default to
> --no-clobber=before,old.
> 
> I think it would be useful to have semantics in .wgetrc where I specify what
> I want my --no-clobber default to be without that meaning I want
> --no-clobber processing on each invocation. It would be nice if I could say
> that I want my default to be "before,old", but to only have that apply when
> I specify --no-clobber on the command line.

Well, I've certainly disliked the fact that --no-clobber means different
times in different modes, and that in certain situations it's impossible
to get the "--clobber" semantics. The fact that there's a convoluted
explanation in the manual about -nc, enumerating none of -r -p or -N, -r
 or -p but not -N, and -N with or without -r or -p (and that the
explanation is currently incorrect when -nd is involved), helps confirm
my belief that it should be several separate options, rather than just one.

I'll certainly be rectifying this in "Reget", if we decide to go with
that proposal; I'm not yet sure whether I'll do it for Wget: probably,
but it'd be a later priority.

- --
Micah J. Cowan
Programmer, musician, typesetting enthusiast, gamer...
http://micah.cowan.name/

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHPep37M8hyUobTrERCMdiAKCAx1QpHfGHRMSMY/xIjUe+Dm9pAwCfZFNI
QmPFhgvNTFH5FkwDU3bfRfE=
=6MKK
-----END PGP SIGNATURE-----

Reply via email to