mirror of
https://github.com/curl/curl.git
synced 2024-12-03 06:20:31 +08:00
68784d73c3
The file format for each option now features a "Example:" header that can provide one or more examples that get rendered appropriately in the output. All options MUST have at least one example or gen.pl complains at build-time. This fix also does a few other minor format and consistency cleanups. Closes #7654
24 lines
1.0 KiB
Makefile
24 lines
1.0 KiB
Makefile
Long: fail-early
|
|
Help: Fail on first transfer error, do not continue
|
|
Added: 7.52.0
|
|
Category: curl
|
|
Example: --fail-early $URL https://two.example
|
|
---
|
|
Fail and exit on the first detected transfer error.
|
|
|
|
When curl is used to do multiple transfers on the command line, it will
|
|
attempt to operate on each given URL, one by one. By default, it will ignore
|
|
errors if there are more URLs given and the last URL's success will determine
|
|
the error code curl returns. So early failures will be "hidden" by subsequent
|
|
successful transfers.
|
|
|
|
Using this option, curl will instead return an error on the first transfer
|
|
that fails, independent of the amount of URLs that are given on the command
|
|
line. This way, no transfer failures go undetected by scripts and similar.
|
|
|
|
This option is global and does not need to be specified for each use of --next.
|
|
|
|
This option does not imply --fail, which causes transfers to fail due to the
|
|
server's HTTP status code. You can combine the two options, however note --fail
|
|
is not global and is therefore contained by --next.
|