Re: [PATCH 2/2] git-gc: skip stashes when expiring reflogs
- From
Jon Loeliger <jdl@freescale.com>
- Date
- Jun 13, 2008, 13:54 UTC
- Message-ID
- <48527C13.2000800@freescale.com>
- In-Reply-To
- <48521EDA.5040802@op5.se>
Andreas Ericsson wrote:
Show 12 quoted lines
> I think these are the options we're faced with: > 1. Never expire stashes (don't shoot the user) > 2. Don't treat stashes specially (shoot the user) > 3. Don't purge stashes when auto-gc-ing (let the users shoot themselves) > 4. Make the behaviour configurable (let the users shoot themselves) > 5. Double the expiration time on stashes and warn for them when they should > normally have expired (during gc, that is) (shoot the user, but warn > first). > > I'm all for #4 and will cook up a patch for that next week when I'm on > vacation unless #1 gets applied before that. >
There are additional choices too, I think, with config-driven variations as well.
At git-gc time, notice a reflog entry for a stash that is about to expire and either convert it to a branch or interactively offer to convert it or delete it.
Provide a command that converts stash entries to branches. Maybe even take over refs/stash/ name-space or so?
All with various config options to do that quietly, interactively, always, never, etc.
jdl