From a51f7f6ce16ba0b108c15d803cab46d1253067af Mon Sep 17 00:00:00 2001 From: Tomasz Janiszewski Date: Fri, 5 Nov 2021 00:35:40 +0100 Subject: [PATCH] curl: add --fail in example (#6630) --- pages/common/curl.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/common/curl.md b/pages/common/curl.md index 27030f235..4a54a4c65 100644 --- a/pages/common/curl.md +++ b/pages/common/curl.md @@ -12,9 +12,9 @@ `curl --remote-name {{http://example.com/filename}}` -- Download a file, following location redirects, and automatically continuing (resuming) a previous file transfer: +- Download a file, following location redirects, and automatically continuing (resuming) a previous file transfer and return an error on server error: -`curl --remote-name --location --continue-at - {{http://example.com/filename}}` +`curl --fail --remote-name --location --continue-at - {{http://example.com/filename}}` - Send form-encoded data (POST request of type `application/x-www-form-urlencoded`). Use `--data @file_name` or `--data @'-'` to read from STDIN: