Skip to content

Commit

Permalink
GHA: add spellcheck
Browse files Browse the repository at this point in the history
wordlist.txt contains accepted 500+ words and spellings otherwise not
treated as fine by the spellchecker.

spellcheck.yaml excludes a few files from checks, as they use too many
unrecognized words

Numerous tiny adjustments were done to content to make this go green.

Closes curl#219
  • Loading branch information
bagder committed Apr 10, 2022
1 parent c5e52ed commit ca9d6f0
Show file tree
Hide file tree
Showing 49 changed files with 709 additions and 121 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/spellcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: spell
on:
push:
branches:
- master
paths:
- '**.md'
pull_request:
branches:
- master

jobs:
check:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Check Spelling
uses: UnicornGlobal/spellcheck-github-actions@master
1 change: 1 addition & 0 deletions badwords.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,4 @@ isn't:is not
url =URL
internet=Internet
isation:ization

16 changes: 8 additions & 8 deletions build/autotools.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@ shared libraries.

One of the differences between linking with a static library compared to
linking with a shared one is in how shared libraries handle their own
dependencies while static ones do not. In order to link with library xyz as a
shared library, it is as basically a matter of adding `-lxyz` to the linker
command line no matter which other libraries xyz itself was built to use. But,
if that xyz is instead a static library we also need to specify each of xyz's
dependencies on the linker command line. curl's configure typically cannot
dependencies while static ones do not. In order to link with library `xyz` as
a shared library, it is as basically a matter of adding `-lxyz` to the linker
command line no matter which other libraries `xyz` itself was built to
use. But, if that `xyz` is instead a static library we also need to specify
each dependency of `xyz` on the linker command line. curl's configure cannot
keep up with or know all possible dependencies for all the libraries it can be
made to build with, so users wanting to build with static libs mostly need to
provide that list of libraries to link with.
Expand All @@ -83,9 +83,9 @@ automatically check for OpenSSL, but modern versions do not.
- NSS: `--with-nss`
- OpenSSL: `--with-openssl`
- Rustls: `--with-rustls` (point to the rustls-ffi install path)
- schannel: `--with-schannel`
- secure transport: `--with-secure-transport`
- Wolfssl: `--with-wolfssl`
- Schannel: `--with-schannel`
- Secure Transport: `--with-secure-transport`
- wolfSSL: `--with-wolfssl`

If you do not specify which TLS library to use, the configure script will
fail. If you want to build *without* TLS support, you must explicitly ask for
Expand Down
4 changes: 2 additions & 2 deletions build/tls.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ using `--without-ssl`.

configure will detect OpenSSL in its default path by default. You can
optionally point configure to a custom install path prefix where it can find
openssl:
OpenSSL:

./configure --with-openssl=/home/user/installed/openssl

Expand All @@ -60,7 +60,7 @@ gnutls:
./configure --with-nss

configure will detect NSS in its default path by default. You can optionally
point configure to a custom install path prefix where it can find nss:
point configure to a custom install path prefix where it can find NSS:

./configure --with-nss=/home/user/installed/nss

Expand Down
4 changes: 2 additions & 2 deletions build/windows.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ use `VC14.30\curl-all.sln` to build curl and libcurl.

If you are a developer and plan to run the curl tool from Visual Studio (eg
you are debugging) with any third-party libraries (such as OpenSSL, wolfSSL or
LibSSH2) then you will need to add the search path of these DLLs to the
libSSH2) then you will need to add the search path of these DLLs to the
configuration's PATH environment. To do that:

1. Open the 'curl-all.sln' or 'curl.sln' solutions
Expand Down Expand Up @@ -88,7 +88,7 @@ DLL Debug - DLL wolfSSL (x64):
C:\Windows;C:\Windows\System32\Wbem

If you are using a configuration that uses multiple third-party library DLLs
(such as DLL Debug - DLL OpenSSL - DLL LibSSH2) then 'Path to DLL' will need
(such as `DLL Debug - DLL OpenSSL - DLL LibSSH2`) then `Path to DLL` will need
to contain the path to both of these.

## Notes
Expand Down
21 changes: 11 additions & 10 deletions cmdline/configfile.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,22 +74,23 @@ config file and uses it if found.

The default config file is checked for in the following places in this order:

1) "$CURL_HOME/.curlrc"
1) `$CURL_HOME/.curlrc`

2) "$XDG_CONFIG_HOME/.curlrc" (Added in 7.73.0)
2) `$XDG_CONFIG_HOME/.curlrc` (Added in 7.73.0)

3) "$HOME/.curlrc"
3) `$HOME/.curlrc`

4) Windows: "%USERPROFILE%\\.curlrc"
4) Windows: `%USERPROFILE%\\.curlrc`

5) Windows: "%APPDATA%\\.curlrc"
5) Windows: `%APPDATA%\\.curlrc`

6) Windows: "%USERPROFILE%\\Application Data\\.curlrc"
6) Windows: `%USERPROFILE%\\Application Data\\.curlrc`

7) Non-Windows: use getpwuid to find the home directory

8) On Windows, if it finds no .curlrc file in the sequence described above, it
checks for one in the same dir the curl executable is placed.
8) On Windows, if it finds no `.curlrc` file in the sequence described above,
it checks for one in the same dir the curl executable is placed.

On Windows two filenames are checked per location: .curlrc and _curlrc,
preferring the former. Older versions on Windows checked for _curlrc only.
On Windows two filenames are checked per location: `.curlrc` and `_curlrc`,
preferring the former. Ancient curl versions on Windows checked for `_curlrc`
only.
4 changes: 2 additions & 2 deletions cmdline/globbing.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ differently. curl, of course, has a solution for these situations as well:
output file name variables.

Each "glob" used in a URL gets a separate variable. They are referenced as
'#[num]' - that means the single character '#' followed by the glob number which
starts with 1 for the first glob and ends with the last glob.
`#[num]` - that means the single character `#` followed by the glob number
which starts with 1 for the first glob and ends with the last glob.

Save the main pages of two different sites:

Expand Down
6 changes: 3 additions & 3 deletions cmdline/passwords.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ curl offers several ways to receive passwords from the user and then
subsequently pass them on or use them to something else.

The most basic curl authentication option is `-u / --user`. It accepts an
argument that is the user name and password, colon separated. Like when alice
wants to request a page requiring HTTP authentication and her password is
`12345`:
argument that is the user name and password, colon separated. Like when
`alice` wants to request a page requiring HTTP authentication and her password
is `12345`:

$ curl -u alice:12345 http://example.com/

Expand Down
28 changes: 14 additions & 14 deletions cmdline/progressmeter.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,17 @@ happening. The different fields in the output have the following meaning:

From left to right:

|Title|Meaning|
|-----|-------|
| % |Percentage completed of the whole transfer |
|Total |Total size of the whole expected transfer (if known) |
| % |Percentage completed of the download |
| Received |Currently downloaded number of bytes |
| % |Percentage completed of the upload |
|Xferd |Currently uploaded number of bytes |
|Average Speed Dload| Average transfer speed of the entire download so far, in number of bytes per second |
|Average Speed Upload| Average transfer speed of the entire upload so far, in number of bytes per second |
|Time Total|Expected time to complete the operation, in HH:MM:SS notation for hours, minutes and seconds |
|Time Current|Time passed since the start of the transfer, in HH:MM:SS notation for hours, minutes and seconds |
|Time Left |Expected time left to completion, in HH:MM:SS notation for hours, minutes and seconds |
|Curr.Speed|Average transfer speed over the last 5 seconds (the first 5 seconds of a transfer is based on less time, of course) in number of bytes per second |
| Title | Meaning |
|------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------|
| `%` | Percentage completed of the whole transfer |
| `Total` | Total size of the whole expected transfer (if known) |
| `%` | Percentage completed of the download |
| `Received` | Currently downloaded number of bytes |
| `%` | Percentage completed of the upload |
| `Xferd` | Currently uploaded number of bytes |
| `Average Speed Dload` | Average transfer speed of the entire download so far, in number of bytes per second |
| `Average Speed Upload` | Average transfer speed of the entire upload so far, in number of bytes per second |
| `Time Total` | Expected time to complete the operation, in `HH:MM:SS` notation for hours, minutes and seconds |
| `Time Current` | Time passed since the start of the transfer, in `HH:MM:SS` notation for hours, minutes and seconds |
| `Time Left` | Expected time left to completion, in `HH:MM:SS` notation for hours, minutes and seconds |
| `Curr. Speed` | Average transfer speed over the last 5 seconds (the first 5 seconds of a transfer is based on less time, of course) in number of bytes per second |
6 changes: 3 additions & 3 deletions cmdline/urls.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# URLs

curl is called curl because a substring in its name is URL (Uniform
Resource Locator). It operates on URLs. URL is the name we casually use for
the web address strings, like the ones we usually see prefixed with http:// or
curl is called curl because a substring in its name is URL (Uniform Resource
Locator). It operates on URLs. URL is the name we casually use for the web
address strings, like the ones we usually see prefixed with `HTTP://` or
starting with www.

URL is, strictly speaking, the former name for these. URI (Uniform Resource
Expand Down
4 changes: 2 additions & 2 deletions cmdline/urls/ftptype.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ is. This is because FTP is a little special and can change mode for a transfer
and thus handle the file differently than if it would use another mode.

You tell curl that the FTP resource is an ASCII type by appending `;type=A` to
the URL. Getting the `foo` file from example.com's root directory using ASCII
could then be made with:
the URL. Getting the `foo` file from the root directory of `example.com` using
ASCII could then be made with:

curl "ftp://example.com/foo;type=A"

Expand Down
4 changes: 2 additions & 2 deletions cmdline/urls/path.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ when you use just the host name like in:
The path is sent to the specified server to identify exactly which resource
that is requested or that will be provided.

The exact use of the path is protocol dependent. For example, getting a file
README from the default anonymous user from an FTP server:
The exact use of the path is protocol dependent. For example, getting the file
`README` from the default anonymous user from an FTP server:

curl ftp://ftp.example.com/README

Expand Down
2 changes: 1 addition & 1 deletion cmdline/urls/scheme.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,5 @@ curl supports or can be made to support (if built so) the following transfer
schemes and protocols:

DICT, FILE, FTP, FTPS, GOPHER, GOPHERS, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS,
MQTT, POP3, POP3S, RTMP, RTMPS, RTSP, SCP, SFTP, SMB, SBMS, SMTP, SMTPS,
MQTT, POP3, POP3S, RTMP, RTMPS, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS,
TELNET and TFTP
6 changes: 3 additions & 3 deletions http/postvspost.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ triggered by HTML or involve a browser. Lots of services, APIs and other systems
allow you to pass in data these days in order to get things done.

If these services expect plain "raw" data or perhaps data formatted as JSON or
similar, you want the [regular POST](post.md) approach. curl's `-d`
option does not alter or encode the data at all but will just send exactly
what you tell it to. Just pay attention to -d's default Content-Type as that
similar, you want the [regular POST](post.md) approach. curl's `-d` option
does not alter or encode the data at all but will just send exactly what you
tell it to. Just pay attention that `-d` sets a default `Content-Type:` that
might not be what you want.
2 changes: 0 additions & 2 deletions http/ranges.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ However, a byte range is only a request to the server. It does not have to
respect the request and in many cases, like when the server automatically
generates the contents on the fly when it is being asked, it will simply refuse
to do it and it then instead responds with the full contents anyway.
<!-- the above is duplicated at libcurl-http-ranges.md -->


You can make curl ask for a range with `-r` or `--range`. If you want the
first 200 bytes out of something:
Expand Down
22 changes: 11 additions & 11 deletions http/response.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,17 +58,17 @@ numeric range and you can use `--write-out` to extract that code as well.
An HTTP 1.1 server can decide to respond with a "chunked" encoded response, a
feature that was not present in HTTP 1.0.

When receiving a chunked response, there is no Content-Length: for the response
to indicate its size. Instead, there is a `Transfer-Encoding: chunked` header
that tells curl there is chunked data coming and then in the response body, the
data comes in a series of "chunks". Every individual chunk starts with the
size of that particular chunk (in hexadecimal), then a newline and then the
contents of the chunk. This is repeated over and over until the end of the
response, which is signalled with a zero sized chunk. The point of this
response encoding is for the client to be able to figure out when the
response has ended even though the server did not know the full size before
it started to send it. This is usually the case when the response is dynamic
and generated at the point when the request comes.
When receiving a chunked response, there is no Content-Length: for the
response to indicate its size. Instead, there is a `Transfer-Encoding:
chunked` header that tells curl there is chunked data coming and then in the
response body, the data comes in a series of "chunks". Every individual chunk
starts with the size of that particular chunk (in hexadecimal), then a newline
and then the contents of the chunk. This is repeated over and over until the
end of the response, which is signaled with a zero sized chunk. The point of
this response encoding is for the client to be able to figure out when the
response has ended even though the server did not know the full size before it
started to send it. This is usually the case when the response is dynamic and
generated at the point when the request comes.

Clients like curl will, of course, decode the chunks and not show the chunk
sizes to users.
Expand Down
2 changes: 1 addition & 1 deletion internals/backends.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,5 @@ duties it needs to do. Each of these internal APIs are powered by alternative
implementations, in many times powered by different third party libraries.

The image above shows the different third party libraries powering different
internal APIs. The purple boxes are "one or more" and the dark grey ones are
internal APIs. The purple boxes are "one or more" and the dark gray ones are
"one of these".
1 change: 0 additions & 1 deletion libcurl-http/ranges.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ However, a byte range is only a request to the server. It does not have to
respect the request and in many cases, like when the server automatically
generates the contents on the fly when it is being asked, it will simply refuse
to do it and it then instead respond with the full contents anyway.
<!--The above is a duplicate of http-ranges.md-->

You can make libcurl ask for a range with `CURLOPT_RANGE`. Like if you want
the first 200 bytes out of something:
Expand Down
2 changes: 1 addition & 1 deletion libcurl/--libcurl.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ what additional arguments to provide to them.
If you specify the filename as a single dash, as in `--libcurl -` you will get
the program written to stdout instead of a file.

As an example, we run a command to just get http://example.com:
As an example, we run a command to get `http://example.com`:

curl http://example.com --libcurl example.c

Expand Down
4 changes: 2 additions & 2 deletions libcurl/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ defined as:

#define LIBCURL_VERSION_NUM 0xXXYYZZ

Where XX, YY and ZZ are the main version, release and patch numbers in
Where `XX` , `YY` and `ZZ` are the main version, release and patch numbers in
hexadecimal. All three number fields are always represented using two digits
(eight bits each). 1.2.0 would appear as "0x010200" while version 9.11.7
appears as "0x090b07".
Expand Down Expand Up @@ -89,7 +89,7 @@ it can return.

You call the function like this:

curl_version_info_data *ver = curl_version_info( CURLVERSION_NOW );
curl_version_info_data *version = curl_version_info( CURLVERSION_NOW );

The data will then be pointing at struct that has or at least can have the
following layout:
Expand Down
8 changes: 4 additions & 4 deletions libcurl/callbacks/progress.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ The **clientp** pointer points to the private data set with
The callback gets told how much data libcurl will transfer and has
transferred, in number of bytes:

- **dltotal** is the total number of bytes libcurl expects to download in
- `dltotal` is the total number of bytes libcurl expects to download in
this transfer.
- **dlnow** is the number of bytes downloaded so far.
- **ultotal** is the total number of bytes libcurl expects to upload in this
- `dlnow` is the number of bytes downloaded so far.
- `ultotal` is the total number of bytes libcurl expects to upload in this
transfer.
- **ulnow** is the number of bytes uploaded so far.
- `ulnow` is the number of bytes uploaded so far.

Unknown/unused argument values passed to the callback will be set to zero
(like if you only download data, the upload size will remain 0). Many times
Expand Down
2 changes: 1 addition & 1 deletion libcurl/curlcode.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## CURLcode return code

Many libcurl functions return a CURLcode. That is a special libcurl typedeffed
Many libcurl functions return a CURLcode. That is a special libcurl typedefed
variable for error codes. It returns `CURLE_OK` (which has the value zero) if
everything is fine and dandy and it returns a non-zero number if a problem was
detected. There are almost one hundred `CURLcode` errors in use, and you can
Expand Down
2 changes: 1 addition & 1 deletion libcurl/getinfo.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ If you want to extract the local port number that was used in that connection:
| CURLINFO_FTP_ENTRY_PATH | char * | The entry path after logging in to an FTP server
| CURLINFO_HEADER_SIZE | long | Number of bytes of all headers received
| CURLINFO_HTTP_CONNECTCODE | long | Last proxy CONNECT response code
| CURLINFO_HTTP_VERSION | long | The http version used in the connection
| CURLINFO_HTTP_VERSION | long | The HTTP version used in the connection
| CURLINFO_HTTPAUTH_AVAIL | long | Available HTTP authentication methods (bitmask)
| CURLINFO_LASTSOCKET | long | Last socket used
| CURLINFO_LOCAL_IP | char * | Local-end IP address of last connection
Expand Down
2 changes: 1 addition & 1 deletion libcurl/options/info.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,6 @@ like this:

There is only one bit with a defined meaning in 'flags': if
`CURLOT_FLAG_ALIAS` is set, it means that that option is an "alias". A name
provided for backwards compatiblity that is nowadays rather served by an
provided for backwards compatibility that is nowadays rather served by an
option with another name. If you lookup the ID for an alias, you will get the
new canonical name for that option.
4 changes: 2 additions & 2 deletions libcurl/options/strings.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ Set a URL in the handle:

## `CURLOPT_POSTFIELDS`

The exeception to the rule that libcurl always copies data,
The exception to the rule that libcurl always copies data,
`CURLOPT_POSTFIELDS` only stores the pointer to the data, meaning an
appliction using this option **must** keep the memory around for the entire
application using this option **must** keep the memory around for the entire
duration of the associated transfer.

If that is problematic, an alternative is to instead use
Expand Down
2 changes: 1 addition & 1 deletion libcurl/proxies.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ other port numbers than 80 and 443.
An HTTPS proxy is similar to an HTTP proxy but allows the client to connect to
it using a secure HTTPS connection. Since the proxy connection is separate
from the connection to the remote site even in this situation, as HTTPS to the
remote site will be tunnelled through the HTTPS connection to the proxy,
remote site will be tunneled through the HTTPS connection to the proxy,
libcurl provides a whole set of TLS options for the proxy connection that are
separate from the connection to the remote host.

Expand Down
Loading

0 comments on commit ca9d6f0

Please sign in to comment.