cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: simplified progress-bar for dumb terminals

From: Kamil Dudka <kdudka_at_redhat.com>
Date: Wed, 4 Apr 2012 14:38:42 +0200

On Monday 02 April 2012 15:59:09 Daniel Stenberg wrote:
> On Mon, 2 Apr 2012, Kamil Dudka wrote:
> > dracut developers are asking us to implement a simplified progress bar
> > that would be similar to the output of --progress-bar but compatible with
> > terminals that do not support the '\r' character:
> >
> > https://bugzilla.redhat.com/show_bug.cgi?id=806426
> >
> > Does such an enhancement make sense? Would it be accepted upstream?
>
> I think we can accept such a change.
>
> Maybe such a fix could (try to) detect terminal type and automatically
> switch to the simpler mode?

I was more thinking of a new option for this. Nevertheless, detecting term
capabilities might also be a solution. The problem is that we need to link
an additional library to access this information. Or am I missing something?

> Anyway, how would it work/look?

Please have a look at the attached patch. Any feedback is welcome.

Kamil

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html

Received on 2012-04-04