"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Stefan Sperling <stsp@stsp.name>
Subject:
Re: Supress progress for update and checkout
To:
Tracey Emery <tracey@traceyemery.net>
Cc:
gameoftrees@openbsd.org
Date:
Fri, 10 Sep 2021 22:42:44 +0200

Download raw body.

Thread
On Fri, Sep 10, 2021 at 02:25:27PM -0600, Tracey Emery wrote:
> Hello,
> 
> The following supresses the output for update and checkout. Running
> these commands on large repos makes the terminal unusable.
> 
> This simply adds a couple of new callbacks that don't printf output.
> 
> Is there a better way to do this, or ok?

I would stick a new 'verbosity' flag into struct got_checkout_progress_arg
and struct got_update_progress_arg. Let it default to zero and set it to -1
if -q is used. The callbacks can then check for upa->verbosity >= 0 before
printing things. That would match how 'fetch' and 'clone' handle this.