On 2025-04-29, Daniel Stenberg wrote:
On Tue, 29 Apr 2025, Aleksei wrote:
curl --etag-compare file0.etag --etag-save file0.etag $URL
... which only downloads the URL again if it is different than the
last download.
If they work together in a single invocation then great, no enhancement
needed. Man page describes ETag usage in separate requests:
Use the option --etag-save to first save the ETag from a response, and
then use this option to compare against the saved ETag in a
**subsequent request**.
It saves the etag from this transfer for the purpose of using in the
next command line.
The compare option however uses the existing file contents for *this*
command line.
--
/ daniel.haxx.se || https://rock-solid.curl.dev
Thanks for explanations Daniel, all clear now. Perhaps these things
should be mentioned in the man page, the current --etag-save and
--etag-compare sections gave me a clear impression these options are to
be used in separate curl invocations.
--
Unsubscribe: https://lists.haxx.se/mailman/listinfo/curl-users
Etiquette: https://curl.se/mail/etiquette.html