Artifactspublic-v0

curl

master
ply4 git calls62 ms289 KiB3 cachedprotocol v2
167 lines5.0 KiBRaw

NAME

wcurl - a simple wrapper around curl to easily download files.

SYNOPSIS

wcurl <URL>...

wcurl [--curl-options <CURL_OPTIONS>]... [--dry-run] [--no-decode-filename] [-o|-O|--output <PATH>] [--] <URL>...

wcurl [--curl-options=<CURL_OPTIONS>]... [--dry-run] [--no-decode-filename] [--output=<PATH>] [--] <URL>...

wcurl -V|--version

wcurl -h|--help

DESCRIPTION

wcurl is a simple curl wrapper which lets you use curl to download files without having to remember any parameters.

Call wcurl with a list of URLs you want to download and wcurl picks sane defaults.

If you need anything more complex, you can provide any of curl's supported parameters via the --curl-options option. Beware that you likely should be using curl directly if your use case is not covered.

By default, wcurl does:

* Percent-encode whitespace in URLs;

* Download multiple URLs in parallel

if the installed curl's version is \>= 7.66.0 (--parallel);

* Use a total number of 5 parallel connections to the same protocol + hostname + port number target

if the installed curl's version is \>= 8.16.0 (--parallel-max-host);

* Follow redirects;

* Automatically choose a filename as output;

* Avoid overwriting files

if the installed curl's version is \>= 7.83.0 (--no-clobber);

* Perform retries;

* Set the downloaded file timestamp

to the value provided by the server, if available;

* Default to https

if the URL does not contain any scheme;

* Disable curl's URL globbing parser

so {} and [] characters in URLs are not treated specially;

* Percent-decode the resulting filename;

* Use 'index.html' as the default filename

if there is none in the URL, or if it is '-'.

OPTIONS

--curl-options, --curl-options=<CURL_OPTIONS>...

Specify extra options to be passed when invoking curl. May be specified more than once.

-o, -O, --output, --output=<PATH>

Use the provided output path instead of getting it from the URL. If multiple URLs are provided, resulting files share the same name with a number appended to the end (curl >= 7.83.0). If this option is provided multiple times, only the last value is considered.

--no-decode-filename

Do not percent-decode the output filename, even if the percent-encoding in the URL was done by wcurl, e.g.: The URL contained whitespace.

--dry-run

Do not actually execute curl, print what would be invoked.

-V, --version

Print version information.

-h, --help

Print help message.

CURL_OPTIONS

Any option supported by curl can be set here. This is not used by wcurl; it is instead forwarded to the curl invocation.

The value is split on whitespace (spaces, tabs and newlines) and each resulting word is passed to curl as a separate argument. Quotes and backslashes are not interpreted, so an argument containing whitespace cannot be passed this way. For example, --curl-options='-H "Cookie: a=1; b=2"' passes the four arguments -H, "Cookie:, a=1; and b=2" to curl, which treats the extra words as URLs to download.

To pass arguments that contain whitespace, write them to a curl config file and pass it with --curl-options="--config <FILE>", or use curl directly.

Everything in <CURL_OPTIONS> becomes part of the curl command line, so never build it from untrusted input.

URL

URL to be downloaded. Anything that is not a parameter is considered an URL. Whitespace is percent-encoded and the URL is passed to curl, which then performs the parsing. May be specified more than once.

EXAMPLES

Download a single file:

wcurl example.com/filename.txt

Download two files in parallel:

wcurl example.com/filename1.txt example.com/filename2.txt

Download a file passing the --progress-bar and --http2 flags to curl:

wcurl --curl-options="--progress-bar --http2" example.com/filename.txt

Resume from an interrupted download. The options necessary to resume the download (--clobber --continue-at -) must be the last options specified in --curl-options. Note that the only way to resume interrupted downloads is to allow wcurl to overwrite the destination file:

wcurl --curl-options="--clobber --continue-at -" example.com/filename.txt

Download multiple files without a limit of concurrent connections per host (the default limit is 5):

wcurl --curl-options="--parallel-max-host 0" example.com/filename1.txt example.com/filename2.txt

AUTHORS

Samuel Henrique \<samueloph@debian.org\>
Sergio Durigan Junior \<sergiodj@debian.org\>
and many contributors, see the AUTHORS file.

REPORTING BUGS

If you experience any problems with wcurl that you do not experience with curl, submit an issue on GitHub: https://github.com/curl/wcurl

wcurl is licensed under the curl license

1---
2c: Copyright (C) Samuel Henrique <samueloph@debian.org>, Sergio Durigan Junior <sergiodj@debian.org> and many contributors, see the AUTHORS file.
3SPDX-License-Identifier: curl
4Title: wcurl
5Section: 1
6Source: wcurl
7See-also:
8 - curl (1)
9 - trurl (1)
10Added-in: n/a
11---
13# NAME
15**wcurl** - a simple wrapper around curl to easily download files.
17# SYNOPSIS
19**wcurl \<URL\>...**
21**wcurl [--curl-options \<CURL_OPTIONS\>]... [--dry-run] [--no-decode-filename] [-o|-O|--output \<PATH\>] [--] \<URL\>...**
23**wcurl [--curl-options=\<CURL_OPTIONS\>]... [--dry-run] [--no-decode-filename] [--output=\<PATH\>] [--] \<URL\>...**
25**wcurl -V|--version**
27**wcurl -h|--help**
29# DESCRIPTION
31**wcurl** is a simple curl wrapper which lets you use curl to download files
32without having to remember any parameters.
34Call **wcurl** with a list of URLs you want to download and **wcurl**
35picks sane defaults.
37If you need anything more complex, you can provide any of curl's supported
38parameters via the **--curl-options** option. Beware that you likely should
39be using curl directly if your use case is not covered.
41By default, **wcurl** does:
43## * Percent-encode whitespace in URLs;
45## * Download multiple URLs in parallel
46 if the installed curl's version is \>= 7.66.0 (--parallel);
48## * Use a total number of 5 parallel connections to the same protocol + hostname + port number target
49 if the installed curl's version is \>= 8.16.0 (--parallel-max-host);
51## * Follow redirects;
53## * Automatically choose a filename as output;
55## * Avoid overwriting files
56 if the installed curl's version is \>= 7.83.0 (--no-clobber);
58## * Perform retries;
60## * Set the downloaded file timestamp
61 to the value provided by the server, if available;
63## * Default to https
64 if the URL does not contain any scheme;
66## * Disable curl's URL globbing parser
67 so {} and [] characters in URLs are not treated specially;
69## * Percent-decode the resulting filename;
71## * Use 'index.html' as the default filename
72 if there is none in the URL, or if it is '-'.
74# OPTIONS
76## --curl-options, --curl-options=\<CURL_OPTIONS\>...
78Specify extra options to be passed when invoking curl. May be specified more
79than once.
81## -o, -O, --output, --output=\<PATH\>
83Use the provided output path instead of getting it from the URL. If multiple
84URLs are provided, resulting files share the same name with a number appended to
85the end (curl \>= 7.83.0). If this option is provided multiple times, only the
86last value is considered.
88## --no-decode-filename
90Do not percent-decode the output filename, even if the percent-encoding in the
91URL was done by **wcurl**, e.g.: The URL contained whitespace.
93## --dry-run
95Do not actually execute curl, print what would be invoked.
97## -V, \--version
99Print version information.
101## -h, \--help
103Print help message.
105# CURL_OPTIONS
107Any option supported by curl can be set here. This is not used by **wcurl**; it
108is instead forwarded to the curl invocation.
110The value is split on whitespace (spaces, tabs and newlines) and each resulting
111word is passed to curl as a separate argument. Quotes and backslashes are not
112interpreted, so an argument containing whitespace cannot be passed this way. For
113example, **--curl-options='-H "Cookie: a=1; b=2"'** passes the four arguments
114`-H`, `"Cookie:`, `a=1;` and `b=2"` to curl, which treats the extra words as
115URLs to download.
117To pass arguments that contain whitespace, write them to a curl config file and
118pass it with **--curl-options="--config \<FILE\>"**, or use curl directly.
120Everything in \<CURL_OPTIONS\> becomes part of the curl command line, so never
121build it from untrusted input.
123# URL
125URL to be downloaded. Anything that is not a parameter is considered
126an URL. Whitespace is percent-encoded and the URL is passed to curl, which
127then performs the parsing. May be specified more than once.
129# EXAMPLES
131Download a single file:
133**wcurl example.com/filename.txt**
135Download two files in parallel:
137**wcurl example.com/filename1.txt example.com/filename2.txt**
139Download a file passing the **--progress-bar** and **--http2** flags to curl:
141**wcurl --curl-options="--progress-bar --http2" example.com/filename.txt**
143Resume from an interrupted download. The options necessary to resume the download
144(`--clobber --continue-at -`) must be the **last** options specified in `--curl-options`.
145Note that the only way to resume interrupted downloads is to allow wcurl to overwrite
146the destination file:
148**wcurl --curl-options="--clobber --continue-at -" example.com/filename.txt**
150Download multiple files without a limit of concurrent connections per host (the default limit is 5):
152**wcurl --curl-options="--parallel-max-host 0" example.com/filename1.txt example.com/filename2.txt**
154# AUTHORS
156 Samuel Henrique \<samueloph@debian.org\>
157 Sergio Durigan Junior \<sergiodj@debian.org\>
158 and many contributors, see the AUTHORS file.
160# REPORTING BUGS
162If you experience any problems with **wcurl** that you do not experience with
163curl, submit an issue on GitHub: https://github.com/curl/wcurl
165# COPYRIGHT
167**wcurl** is licensed under the curl license
Diagnostics4 git calls · 62 ms
CallStatusSizeTime062 ms
discover200152 B2 ms
git.upload-pack discover
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
git.upstream.dur_ms=2
git.response.bytes=152
git.server.agent=gitty/1.0
git.server.object_format=sha1
git.server.caps=agent ls-refs fetch object-format
git.server.fetch=shallow filter sideband-all
git.protocol.version=2
git.pkt.frames=8
git.pkt.data=6
git.pkt.flush=2
git.pkt.delim=0
git.pkt.bytes=152
git.pkt.payload.max=34
ls-refs200149 B · hit2 ms
git.upload-pack ls-refs
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
git.upstream.dur_ms=2
git.response.bytes=149
git.response.cache=HIT
git.response.duration_ms=2
git.protocol.version=2
git.pkt.frames=3
git.pkt.data=2
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=149
git.pkt.payload.max=78
git.ls_refs.count=2
git.ls_refs.head=refs/heads/master
fetchblob:none · deepen 10200287 KiB · hit3 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=2
git.response.bytes=293470
git.response.cache=HIT
git.response.duration_ms=3
git.fetch.filter=blob:none
git.fetch.filter.requested=tree:0
git.fetch.filter.fallback=blob:none
git.fetch.filter.learned=false
git.fetch.wants=31c911efe5652725e930f4d2e60c9060e5f6646d
git.fetch.haves.count=0
git.fetch.deepen=10
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=10
git.pkt.data=8
git.pkt.flush=1
git.pkt.delim=1
git.pkt.bytes=293470
git.pkt.payload.max=65516
git.sideband.band1.bytes=293354
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0
git.pack.objects=87
git.pack.bytes=293354
git.pack.ofs_delta=0
git.pack.ref_delta=1
git.pack.chain.max=1
git.pack.trailer=6a646bcda6740bab42e321b51998b52ea15146c0
git.pack.full=86
Open pack map
fetch2002.2 KiB · hit57 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=56
git.response.bytes=2286
git.response.cache=HIT
git.response.duration_ms=57
git.fetch.wants=59f426796918bf591024eed1f39161e6e0a9eb40
git.fetch.haves.count=0
git.fetch.deepen=0
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=3
git.pkt.data=2
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=2286
git.pkt.payload.max=2265
git.sideband.band1.bytes=2264
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0

Each row is one HTTP round trip ply made to the git server for this page, on one timeline. discover asks what the server speaks, ls-refs lists branch tips, fetch brings objects by id. A hit was served by Workers Cache. Tap a row for its wire details.

Remote
https://5ad2236b39de4c8bd8f6270ea63f3ea9.artifacts.cloudflare.net/git/public-v0/curl.git
Ref
refs/heads/master
Commit
31c911efe5652725e930f4d2e60c9060e5f6646d
cf-ray
a5e2bd0eb9d4cfc3
Request
26d185cf…
Protocol
v2 · sha1
Agent
gitty/1.0
Filter
advertised
Fetch
shallow filter sideband-all
Capabilities
agent ls-refs fetch object-format