Re: git gc & deleted branches
- From
Jeff King <peff@peff.net>
- Date
- May 8, 2008, 20:56 UTC
- Message-ID
- <20080508205652.GB32762@sigill.intra.peff.net>
- In-Reply-To
- <48235D99.2040407@nrlssc.navy.mil>
On Thu, May 08, 2008 at 03:07:53PM -0500, Brandon Casey wrote:
Show 5 quoted lines
> btw, this is _really_ a non-issue. It seems to keep coming up on the list. > > Just know that each one of the config options that you set to zero, including > the one Jeff suggested setting to "now", is a safety mechanism that is there > to ensure that you never ever lose data and that mistakes are recoverable.
Yes, I want to chime in since I have been giving advice in such threads: Please don't construe my help as any sort of endorsement of this behavior. Git tries hard not to lose your data, and it is almost always a bad idea to try to override these safety checks unless you really know what you are doing.
And even then, try to consider balancing a bit of freed disk space (and generally _no_ performance gain, because git is very good about not looking at objects that aren't necessary to the current operation) versus thinking "oops, I wish I still had that data" in a few days.
I can think offhand of only one time when it was truly useful for me to prune aggressively, and it was a very special case: a pathologically large repo for which I was doing a one-shot conversion from another format (and I wanted to prune failed attempts).
-Peff