Hi,
On Wed, 2 Jul 2008, Nanako Shiraishi wrote:
A stash records the state of the files in the working tree as a merge
between the HEAD and another commit that records the state of the index,
that in turn is a child commit of the HEAD commit. In order to later
apply (or pop) the stash, however, only the tree objects of these three
commits are necessary.
This patch changes the structure of a stash to use a parentless new
commit that has the same tree as the HEAD commit, in place of the HEAD
commit. This way, a stash does not keep the history that leads to the
HEAD commit reachable, even if the stash is kept forever.
May I register my suspicion that this is the wrong direction to go?
I actually find it quite nice that I can easily see in gitk where I
spawned off a certain stash, indeed, how the recent stash history
(manually specified with "stash@{0} stash@{1} stash@{2}" [*1*]), relates
to the current branch's history.
Ciao,
Dscho
P.S.: I vaguely remember that I once wrote a patch to turn "stash@{0..2}"
into exactly the same, but I do not remember why I did not follow up on
it. Was it refuted, or unwanted?