mirror of
https://github.com/curl/curl.git
synced 2026-08-05 03:06:13 +03:00
curl: add --remove-on-error
If a transfer returns an error, using this option makes curl remove the leftover downloded (partial) local file before exiting. Added test 376 to verify Closes #8503
This commit is contained in:
parent
7b0fd39db2
commit
08a96c6e4e
9 changed files with 93 additions and 2 deletions
|
|
@ -203,6 +203,7 @@ DPAGES = \
|
|||
remote-name-all.d \
|
||||
remote-name.d \
|
||||
remote-time.d \
|
||||
remove-on-error.d \
|
||||
request-target.d \
|
||||
request.d \
|
||||
resolve.d \
|
||||
|
|
|
|||
12
docs/cmdline-opts/remove-on-error.d
Normal file
12
docs/cmdline-opts/remove-on-error.d
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
Long: remove-on-error
|
||||
Help: Remove output file on errors
|
||||
See-also: fail
|
||||
Category: curl
|
||||
Example: --remove-on-error -o output $URL
|
||||
Added: 7.83.0
|
||||
---
|
||||
When curl returns an error when told to save output in a local file, this
|
||||
option removes that saved file before exiting. This prevevents curl from
|
||||
leaving a partial file in the case of an error during transfer.
|
||||
|
||||
If the output is not a file, this option has no effect.
|
||||
|
|
@ -191,6 +191,7 @@
|
|||
--remote-name (-O) 4.0
|
||||
--remote-name-all 7.19.0
|
||||
--remote-time (-R) 7.9
|
||||
--remove-on-error 7.83.0
|
||||
--request (-X) 6.0
|
||||
--request-target 7.55.0
|
||||
--resolve 7.21.3
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue