From: Daniel Stenberg Date: Thu, 27 Jun 2024 20:54:28 +0000 (+0200) Subject: managen: introduce "Multi: per-URL" X-Git-Tag: curl-8_9_0~164 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2d3a51e3670310d8a4723bbc98d3fc1a04c74ac6;p=thirdparty%2Fcurl.git managen: introduce "Multi: per-URL" For -O, -o and -T that are used once per specified URL. Closes #14045 --- diff --git a/docs/cmdline-opts/MANPAGE.md b/docs/cmdline-opts/MANPAGE.md index 1f9749bc51..3e2e7151f6 100644 --- a/docs/cmdline-opts/MANPAGE.md +++ b/docs/cmdline-opts/MANPAGE.md @@ -45,7 +45,7 @@ A line that starts with ``. Help: (short text for the --help output for this option) Long: (long form name, without dashes) Magic: (description of "magic" options) - Multi: single/append/boolean/mutex/custom (if used more than once) + Multi: single/append/boolean/mutex/custom/per-URL (if used more than once) Mutexed: (space separated list of options this overrides, no dashes) Protocols: (space separated list for which protocols this option works) Requires: (space separated list of features this requires, no dashes) diff --git a/docs/cmdline-opts/output.md b/docs/cmdline-opts/output.md index 53f6583272..548e02f15c 100644 --- a/docs/cmdline-opts/output.md +++ b/docs/cmdline-opts/output.md @@ -7,7 +7,7 @@ Short: o Help: Write to file instead of stdout Category: important curl Added: 4.0 -Multi: append +Multi: per-URL See-also: - remote-name - remote-name-all diff --git a/docs/cmdline-opts/remote-name.md b/docs/cmdline-opts/remote-name.md index 5d2fcdcb2b..041800fa92 100644 --- a/docs/cmdline-opts/remote-name.md +++ b/docs/cmdline-opts/remote-name.md @@ -6,13 +6,14 @@ Short: O Help: Write output to file named as remote file Category: important output Added: 4.0 -Multi: append +Multi: per-URL See-also: - remote-name-all - output-dir - remote-header-name Example: - -O https://example.com/filename + - -O https://example.com/filename -O https://example.com/file2 --- # `--remote-name` diff --git a/docs/cmdline-opts/upload-file.md b/docs/cmdline-opts/upload-file.md index 74e7af3025..7e9ffbf1e6 100644 --- a/docs/cmdline-opts/upload-file.md +++ b/docs/cmdline-opts/upload-file.md @@ -7,7 +7,7 @@ Arg: Help: Transfer local FILE to destination Category: important upload Added: 4.0 -Multi: append +Multi: per-URL See-also: - get - head @@ -17,6 +17,7 @@ Example: - -T file $URL - -T "img[1-1000].png" ftp://ftp.example.com/ - --upload-file "{file1,file2}" $URL + - -T file -T file2 $URL $URL --- # `--upload-file` diff --git a/scripts/managen b/scripts/managen index f384f8953e..8c057355cc 100755 --- a/scripts/managen +++ b/scripts/managen @@ -704,6 +704,11 @@ sub single { elsif($multi eq "custom") { ; # left for the text to describe } + elsif($multi eq "per-URL") { + push @extra, + "${pre}--$long is associated with a single URL. Use it once per URL\n". + "when you use several URLs in a command line.\n"; + } else { print STDERR "$f:$line:1:ERROR: unrecognized Multi: '$multi'\n"; return 2;