curl/docs/cmdline-opts/remove-on-error.md
Yedaya Katsman 62bfcb0c44
help: add flags to output and ssh categories
- Add --output, --remove-on-error, --output-dir and --created-dirs to
  the output help category

- Add --hostpubmd5, --hostpubsha256, --insecure (-k), and --pubkey to
  the ssh help category

Closes #14076
2024-07-04 09:58:23 +02:00

553 B

c SPDX-License-Identifier Long Help Category Added Multi See-also Example
Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al. curl remove-on-error Remove output file on errors curl output 7.83.0 boolean
fail
--remove-on-error -o output $URL

--remove-on-error

Remove output file if an error occurs. If curl returns an error when told to save output in a local file. This prevents curl from leaving a partial file in the case of an error during transfer.

If the output is not a regular file, this option has no effect.