Re: [PATCH 2/2] git-gc: skip stashes when expiring reflogs
- From
Wincent Colaiuta <win@wincent.com>
- Date
- Jun 13, 2008, 19:35 UTC
- Message-ID
- <5F01034D-8964-47AC-8FB5-F68C44D7FFD5@wincent.com>
- In-Reply-To
- <7v3anhuonj.fsf@gitster.siamese.dyndns.org>
El 13/6/2008, a las 21:21, Junio C Hamano escribió:
Show 7 quoted lines
> To stash is like putting something in /tmp on a system that runs a > cron > job to clean out cruft from there once in a while. Another analogy > is to > spitting an information out to syslog, so that it is kept until logs > are > rotated.
Judging from the number of people who have chimed in on this thread saying "I expect Git to remember what I told it to remember" indicates that all too few think of the stash as being like "/tmp" or a logfile. There are two problems:
1) the name of the command, "stash" (and worse still "stash _save_") is giving people a misleading impression about what it does
2) the documentation isn't clear enough about what the command does, or people don't read it
I suspect that no matter how good the documentation is, a command called "git stash save" that remembers stuff only temporarily will continue to evoke reactions of puzzlement for as long as it works that way. Seeing as Git is usually extremely conservative about throwing away people's stuff, the ephemeralness of "git stash" backing store is likely to be quite surprising for many.
What are the options?
- improve the documentation
- rename the command (can't see that happening)
- change the behaviour to "keep" until popped/cleared
I think the latter's the best, and a patch for it was already posted at the beginning of this thread.
Cheers, Wincent