curl.1: remove mentions of really old version changes

To make the man page more readable, this change removes all references
to changes in support/versions etc that happened before 7.30.0 from the
curl.1 output file. 7.30.0 was released on Apr 12 2013. This particular
limit is a bit arbitrary but was fairly easy to grep for.

It is handled like this: the 'Added' keyword is only used in output if
it refers to 7.30.0 or later. All occurances of "(Added in $VERSION)" in
description will be stripped out if the mentioned $VERSION is from
before 7.30.0. It is therefore important that the "Added in..."
references are always written exactly like that - and on a single line,
not split over two.

This change removes about 80 version number references from curl.1, down
to 138 from 218.

Closes #7786
This commit is contained in:
Daniel Stenberg 2021-09-28 10:30:59 +02:00
parent 6f19f68e93
commit ebf18468c0
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2
12 changed files with 46 additions and 27 deletions

View File

@ -30,7 +30,8 @@ If this option is used several times, the last one will be used. Disable the
use of PORT with --ftp-pasv. Disable the attempt to use the EPRT command
instead of PORT by using --disable-eprt. EPRT is really PORT++.
Since 7.19.5, you can append \&":[start]-[end]\&" to the right of the address,
to tell curl what TCP port range to use. That means you specify a port range,
from a lower to a higher number. A single number works as well, but do note
that it increases the risk of failure since the port may not be available.
You can also append \&":[start]-[end]\&" to the right of the address, to tell
curl what TCP port range to use. That means you specify a port range, from a
lower to a higher number. A single number works as well, but do note that it
increases the risk of failure since the port may not be available.
(Added in 7.19.5)

View File

@ -76,6 +76,12 @@ sub manpageify {
sub printdesc {
my @desc = @_;
for my $d (@desc) {
if($d =~ /\(Added in ([0-9.]+)\)/i) {
my $ver = $1;
if(too_old($ver)) {
$d =~ s/ *\(Added in $ver\)//gi;
}
}
if($d !~ /^.\\"/) {
# **bold**
$d =~ s/\*\*([^ ]*)\*\*/\\fB$1\\fP/g;
@ -127,8 +133,25 @@ sub protocols {
}
}
sub too_old {
my ($version)=@_;
if($version =~ /^(\d+)\.(\d+)\.(\d+)/) {
my $a = $1 * 1000 + $2 * 10 + $3;
if($a < 7300) {
# we consider everything before 7.30.0 to be too old to mention
# specific changes for
return 1;
}
}
return 0;
}
sub added {
my ($standalone, $data)=@_;
if(too_old($data)) {
# don't mention ancient additions
return "";
}
if($standalone) {
return ".SH \"ADDED\"\nAdded in curl version $data\n";
}

View File

@ -61,8 +61,8 @@ analyze the TLS traffic in real time using network analyzing tools such as
Wireshark. This works with the following TLS backends: OpenSSL, libressl,
BoringSSL, GnuTLS, NSS and wolfSSL.
.SH "PROXY PROTOCOL PREFIXES"
Since curl version 7.21.7, the proxy string may be specified with a
protocol:// prefix to specify alternative proxy protocols.
The proxy string may be specified with a protocol:// prefix to specify
alternative proxy protocols. (Added in 7.21.7)
If no protocol is specified in the proxy string or if the string doesn't match
a supported one, the proxy will be treated as an HTTP proxy.

View File

@ -194,6 +194,4 @@ options -O, -L and -v at once as -OLv.
In general, all boolean options are enabled with --**option** and yet again
disabled with --**no-**option. That is, you use the exact same option name
but prefix it with "no-". However, in this list we mostly only list and show
the --option version of them. (This concept with --no options was added in
7.19.0. Previously most options were toggled on/off through repeated use of
the same command line option.)
the --option version of them.

View File

@ -13,8 +13,6 @@ Example, allow only HTTP and HTTPS on redirect:
curl --proto-redir -all,http,https http://example.com
By default curl will allow HTTP, HTTPS, FTP and FTPS on redirect (7.65.2).
Older versions of curl allowed all protocols on redirect except several
disabled for security reasons: Since 7.19.4 FILE and SCP are disabled, and
since 7.40.0 SMB and SMBS are also disabled. Specifying *all* or *+all*
enables all protocols on redirect, including those disabled for security.
By default curl will only allow HTTP, HTTPS, FTP and FTPS on redirect (since
7.65.2). Specifying *all* or *+all* enables all protocols on redirects, which
is not good for security.

View File

@ -10,7 +10,7 @@ Use the specified proxy.
The proxy string can be specified with a protocol:// prefix. No protocol
specified or http:// will be treated as HTTP proxy. Use socks4://, socks4a://,
socks5:// or socks5h:// to request a specific SOCKS version to be used.
(The protocol support was added in curl 7.21.7)
(Added in 7.21.7)
HTTPS proxy support via https:// protocol prefix was added in 7.52.0 for
OpenSSL, GnuTLS and NSS.

View File

@ -30,8 +30,8 @@ Specifies a custom FTP command to use instead of LIST when doing file lists
with FTP.
(POP3)
Specifies a custom POP3 command to use instead of LIST or RETR. (Added in
7.26.0)
Specifies a custom POP3 command to use instead of LIST or RETR.
(Added in 7.26.0)
(IMAP)
Specifies a custom IMAP command to use instead of LIST. (Added in 7.30.0)

View File

@ -12,8 +12,8 @@ and passing the address on to the proxy.
This option overrides any previous use of --proxy, as they are mutually
exclusive.
Since 7.21.7, this option is superfluous since you can specify a socks4 proxy
with --proxy using a socks4:// protocol prefix.
This option is superfluous since you can specify a socks4 proxy with --proxy
using a socks4:// protocol prefix. (Added in 7.21.7)
Since 7.52.0, --preproxy can be used to specify a SOCKS proxy at the same time
--proxy is used with an HTTP/HTTPS proxy. In such a case curl first connects to

View File

@ -11,8 +11,8 @@ assumed at port 1080. This asks the proxy to resolve the host name.
This option overrides any previous use of --proxy, as they are mutually
exclusive.
Since 7.21.7, this option is superfluous since you can specify a socks4a proxy
with --proxy using a socks4a:// protocol prefix.
This option is superfluous since you can specify a socks4a proxy with --proxy
using a socks4a:// protocol prefix. (Added in 7.21.7)
Since 7.52.0, --preproxy can be used to specify a SOCKS proxy at the same time
--proxy is used with an HTTP/HTTPS proxy. In such a case curl first connects to

View File

@ -11,8 +11,8 @@ the port number is not specified, it is assumed at port 1080.
This option overrides any previous use of --proxy, as they are mutually
exclusive.
Since 7.21.7, this option is superfluous since you can specify a socks5
hostname proxy with --proxy using a socks5h:// protocol prefix.
This option is superfluous since you can specify a socks5 hostname proxy with
--proxy using a socks5h:// protocol prefix. (Added in 7.21.7)
Since 7.52.0, --preproxy can be used to specify a SOCKS proxy at the same time
--proxy is used with an HTTP/HTTPS proxy. In such a case curl first connects to

View File

@ -11,8 +11,8 @@ port number is not specified, it is assumed at port 1080.
This option overrides any previous use of --proxy, as they are mutually
exclusive.
Since 7.21.7, this option is superfluous since you can specify a socks5 proxy
with --proxy using a socks5:// protocol prefix.
This option is superfluous since you can specify a socks5 proxy with --proxy
using a socks5:// protocol prefix. (Added in 7.21.7)
Since 7.52.0, --preproxy can be used to specify a SOCKS proxy at the same time
--proxy is used with an HTTP/HTTPS proxy. In such a case curl first connects to

View File

@ -48,8 +48,7 @@ server. (Added in 7.15.4)
.TP
.B http_code
The numerical response code that was found in the last retrieved HTTP(S) or
FTP(s) transfer. In 7.18.2 the alias **response_code** was added to show the
same info.
FTP(s) transfer.
.TP
.B http_connect
The numerical code that was found in the last response (from a proxy) to a