From: Nicolas Pitre <nico@cam.org>
To: Brandon Casey <casey@nrlssc.navy.mil>
Cc: Jeff King <peff@peff.net>,
John Dlugosz <JDlugosz@TradeStation.com>,
git@vger.kernel.org
Subject: Re: dangling commits and blobs: is this normal?
Date: Wed, 22 Apr 2009 16:00:06 -0400 (EDT) [thread overview]
Message-ID: <alpine.LFD.2.00.0904221548310.6741@xanadu.home> (raw)
In-Reply-To: <FcecxnoVg4H8G3MKjZgl2T6zCGDer4yYyScIgaweFTNgDCKG65Xiig@cipher.nrlssc.navy.mil>
On Wed, 22 Apr 2009, Brandon Casey wrote:
> Nicolas Pitre wrote:
> > On Wed, 22 Apr 2009, Brandon Casey wrote:
>
> >> I've often wondered whether a plain 'git gc' should adopt the behavior
> >> of --auto with respect to the number of packs. If there were few packs,
> >> then 'git gc' would do an incremental repack, rather than a 'repack -A -d -l'.
> >
> > Why so? Having fewer packs is always a good thing. Having only one
> > pack is of course the optimal situation. The --auto version doesn't do
> > it in the hope of being lightter and less noticeable by the user.
>
> The only reason for avoiding packing all packs into one would be speed in
> this case also. I recall reading complaints or surprise about gc
> repacking all packs into one, so I'm only trying to think about how to
> match program behavior with user expectations.
It's user's expectations that need adjusting then. Making a single pack
is indeed the job of an explicit gc invocation.
> gc does a lot already, and even Jeff wasn't sure what to expect from
> 'git gc' with respect to packs. Possibly an acceptable trade off
> between speed and optimal packing would be to adopt the --auto
> behavior for deciding when to use '-A' with repack.
And what would be the point of manually running 'git gc' then, given
that 'git gc --auto' is already invoked automatically after most commit
creating commands?
I mean, if you consider explicit 'git gc' too long, then simply wait
until you can spare the time, if at all. This is not like a non gc'd
repository suddently becomes non functional.
WRT trade offs, the current behavior is already a pretty good compromize
between speed and optimal packing, the later implying -f to 'git
repack' which is far far slower.
Nicolas
next prev parent reply other threads:[~2009-04-22 20:02 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-21 21:46 dangling commits and blobs: is this normal? John Dlugosz
2009-04-22 15:27 ` Jeff King
2009-04-22 16:53 ` Brandon Casey
2009-04-22 17:39 ` Nicolas Pitre
2009-04-22 18:15 ` Matthieu Moy
2009-04-22 19:08 ` Jeff King
2009-04-22 19:45 ` Brandon Casey
2009-04-22 19:58 ` Jeff King
2009-04-22 20:07 ` Nicolas Pitre
2009-04-23 11:51 ` Matthieu Moy
2009-04-22 19:14 ` Nicolas Pitre
2009-04-22 19:26 ` Brandon Casey
2009-04-22 20:00 ` Nicolas Pitre [this message]
2009-04-22 20:05 ` Jeff King
2009-04-22 20:11 ` Nicolas Pitre
2009-04-23 17:43 ` Geert Bosch
2009-04-23 17:56 ` Shawn O. Pearce
2009-04-23 18:10 ` Geert Bosch
2009-04-23 18:17 ` Matthias Andree
2009-04-23 18:51 ` Nicolas Pitre
2009-04-22 20:15 ` John Dlugosz
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=alpine.LFD.2.00.0904221548310.6741@xanadu.home \
--to=nico@cam.org \
--cc=JDlugosz@TradeStation.com \
--cc=casey@nrlssc.navy.mil \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
/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).