git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sam Vilain <sam@vilain.net>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: Karl Stenerud <kstenerud@gmail.com>, git@vger.kernel.org
Subject: Re: notify alternative to auto gc?
Date: Wed, 30 Jun 2010 14:27:18 +1200	[thread overview]
Message-ID: <1277864838.23613.18.camel@wilber> (raw)
In-Reply-To: <AANLkTil8sHZrfvHetwzjhOsyprsqrf7-XRS3B8qKH7cs@mail.gmail.com>

On Mon, 2010-06-28 at 16:26 +0000, Ævar Arnfjörð Bjarmason wrote:
> On Mon, Jun 28, 2010 at 16:10, Karl Stenerud <kstenerud@gmail.com> wrote:
> > The git help tells me I can disable it by setting gc.auto to 0, while the mailing list archive tells me I also have to set gc.autopacklimit to 0.  This is fine, but if I do that, I won't know when the repo is in need of cleanup.  Is there any option I can set to instruct it to simply TELL me when it's in need of gc?
> 
> Anything that tells you whether you need to gc would incur much of the
> speed penalty that running gc itself does.

See builtin/gc.c:too_many_loose_objects

Checking that gc is required involves opening one directory (objects/17
IIRC), reading all of the entries in it and counting them.  It really
doesn't hurt.

Sam

  parent reply	other threads:[~2010-06-30  2:29 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-28 16:10 notify alternative to auto gc? Karl Stenerud
2010-06-28 16:26 ` Ævar Arnfjörð Bjarmason
2010-06-28 16:52   ` Karl Stenerud
2010-06-29  6:46     ` Matthieu Moy
2010-06-30  2:27   ` Sam Vilain [this message]
2010-06-28 16:27 ` Matthieu Moy
2010-06-28 16:29 ` Chris Packham
2010-06-28 16:56   ` Karl Stenerud
2010-06-28 17:07   ` [PATCH/RFC] Documentation/git-gc.txt: add reference to githooks Chris Packham
2010-06-28 18:43     ` Marc Branchaud
2010-06-29 15:43       ` Junio C Hamano
2010-06-29 16:00         ` Chris Packham
2010-06-29 16:26     ` Junio C Hamano
2010-06-29 18:16       ` Chris Packham
2010-06-30 20:41         ` [PATCHv2] " Chris Packham
2010-09-21 18:14     ` [PATCH/RFC] " David Brown
2010-09-21 20:52       ` Allow git remote add but not git clone ( was Re: [PATCH/RFC] Documentation/git-gc.txt: add reference to githooks) Chris Packham
2010-09-21 21:01         ` David Brown
2010-09-21 23:18       ` Re* [PATCH/RFC] Documentation/git-gc.txt: add reference to githooks Junio C Hamano
2010-06-28 18:58   ` notify alternative to auto gc? Eric Raible
2010-06-28 19:02     ` Jacob Helwig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1277864838.23613.18.camel@wilber \
    --to=sam@vilain.net \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=kstenerud@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).