cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Progress Meter, Statistics

From: Daniel Stenberg <Daniel.Stenberg_at_haxx.nu>
Date: Wed, 23 Feb 2000 16:21:34 +0100

Georg Horn wrote:

> i'm new to this list, since i just (well a few weeks ago) discoverd the
> curl tool.

Welcome!

> 1: Don't display any statistics at all (not the -s switch, since -s
> suppresses errors too...)

'curl -s -S' is probably what you're after!

> 2: Just display a summary at the end of the download, as it happens now
> when the total number of bytes is less than LEAST_SIZE_PROGRESS, but in
> a _single_ line without the \r at the beginning:
> 1174 bytes received in 0.024 seconds (49167 bytes/sec)
> This will be used to determine just the overall transfer rate.

Quite amazingly, this is exactly what the new -w option does (introduced
in the upcoming 6.5). -w takes a string and has a bunch of variable
substitutions to enable you to select what to see.

> 3: Display statitics data in a configurable intervall during the
> download like this:
> TIME RECEIVED % CURR-SPEED
> 00:00:02 1100648 9 1098021
> 00:00:04 3376564 10 1117624
> ...
> This will be used to determine how the transfer rate varies during a
> transfer.

I can see the point in having a feature like this.

> One could use the -s switch for this: -s behaves like it is now, and -sx
> selects option number x from the above list.

I don't see how this can be added to -s (-sx can't be used since that
would be -s and -x written next to each other and -x is already used).

I could however think of a -w -style option where you specify what kind of
line you want to get written intead of the progress meter line with a
steady interval. I would then suggest -W or possibly using the -w for the
format and another flag to enable the interval-output.

This will need a little thinking and debating.

--
   Daniel Stenberg - http://www.contactor.se/~dast - +46-705-44 31 77
   ech`echo xiun|tr nu oc|sed 'sx\([sx]\)\([xoi]\)xo un\2\1 is xg'`ol
Received on 2000-02-23