bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-wget] Metalink support


From: Hubert Tarasiuk
Subject: Re: [Bug-wget] Metalink support
Date: Sat, 4 Jul 2015 01:44:54 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.0.1

W dniu 04.07.2015 o 00:15, Anthony Bryan pisze:
>>
>> Of course it works for me, but we are not talking about me :-)
>>
>> The main question is: what does the typical wget user expect ?
>> I would thinks (s)he expects the download of the file described by the
>> .metalink file. Of course a few users really want to have only the .metalink
>> file (for testing/inspection). So there should be a possibility to do exactly
>> that (e.g. --keep-metalink).
>>
>> Before making any decision/action we should wait for some other voices.
> 
> I'm not sure what the typical wget user expects, but here are some examples.
> 
> if you keep the current behavior, it might be helpful to print to the
> user that they've downloaded a metalink, and how to make wget use it.
> 
> aria2 (another command line metalink downloader) uses these commands
> to download the metalink and process it (download the file described
> by it & do a hash check) by default. you have to specify
> '--follow-metalink=false' to only download the metalink XML file.
I like that option.

Also, I am including the amended patches. There was an issue with
freeing memory when the Metalink parsing failed (I have moved the
metalink_delete call from outside to inside of the 'else' block in
main.c:1806).
> 
> curl on the other hand just downloads the metalink XML file by default
> (like any other file), and requires a '--metalink' option to process a
> local file or URL. (examples & help/man pages follow)
> 
> aria2c URL
> or
> aria2c --metalink-file=filename
> 
> aria2 help:
> 
> -M, --metalink-file=METALINK_FILE The file path to the .meta4 and .metalink
> 
>                               file. Reads input from stdin when '-' is
> 
>                               specified.
> 
> 
>                               Possible Values: /path/to/file, -
> 
> 
> --follow-metalink=true|false|mem If true or mem is specified, when a file
> 
>                               whose suffix is .meta4 or .metalink, or content
> 
>                               type of application/metalink4+xml or
> 
>                               application/metalink+xml is downloaded, aria2
> 
>                               parses it as a metalink file and downloads files
> 
>                               mentioned in it.
> 
>                               If mem is specified, a metalink file is not
> 
>                               written to the disk, but is just kept in memory.
> 
>                               If false is specified, the .metalink file is
> 
>                               downloaded to the disk, but is not parsed as a
> 
>                               metalink file and its contents are not
> 
>                               downloaded.
> 
> 
>                               Possible Values: true, mem, false
> 
>                               Default: true
> 
> 
> 
> from the curl man page:
> 
>       --metalink
> 
>               This option can tell curl to parse and process a given
> URI as Metalink file (both version 3 and 4 (RFC 5854)
> 
>               are supported) and make use of the mirrors listed within
> for failover if there are errors (such as the  file
> 
>               or  server  not being available). It will also verify
> the hash of the file after the download completes. The
> 
>               Metalink file itself is downloaded and processed in
> memory and not stored in the local file system.
> 
> 
>               Example to use a remote Metalink file:
> 
> 
>               curl --metalink http://www.example.com/example.metalink
> 
> 
>               To use a Metalink file in the local file system, use
> FILE protocol (file://):
> 
> 
>               curl --metalink file://example.metalink
> 
> 
>               Please note that if FILE protocol is disabled, there is
> no way to use a local Metalink file at the  time  of
> 
>               this  writing. Also note that if --metalink and
> --include are used together, --include will be ignored. This
> 
>               is because including headers in the response will break
> Metalink parser and if the headers are  included  in
> 
>               the file described in Metalink file, hash check will fail.
> 
> 

Attachment: 0001-Metalink-support.patch
Description: Text Data

Attachment: 0002-Start-HTTP-test-only-when-calling-begin.patch
Description: Text Data

Attachment: 0003-Test-case-for-Metalink-in-XML.patch
Description: Text Data

Attachment: 0004-Support-multiple-headers-with-same-name-in-Python-te.patch
Description: Text Data

Attachment: 0005-Test-case-for-Metalink-over-HTTP.patch
Description: Text Data

Attachment: 0006-Unit-test-for-find_key_value.patch
Description: Text Data

Attachment: 0007-Unit-test-for-has_key.patch
Description: Text Data

Attachment: 0008-Unit-test-for-find_key_values.patch
Description: Text Data

Attachment: 0009-Move-some-Metalink-related-code-from-http.c-to-metal.patch
Description: Text Data

Attachment: 0010-Support-at-most-one-file-signature.-Adapt-comments-t.patch
Description: Text Data

Attachment: 0011-Geolocation-support-for-Metalink-resources.patch
Description: Text Data

Attachment: 0012-Test-preferred-location-in-Metalink-over-HTTP-test-c.patch
Description: Text Data

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]