Re: What's cooking in git.git (topics)
- From
Nicolas Pitre <nico@cam.org>
- Date
- Jan 29, 2007, 04:41 UTC
- Message-ID
- <Pine.LNX.4.64.0701282321390.3021@xanadu.home>
- In-Reply-To
- <Pine.LNX.4.64.0701272049480.3021@xanadu.home>
On Sat, 27 Jan 2007, Nicolas Pitre wrote:
Show 10 quoted lines
> On Sat, 27 Jan 2007, Junio C Hamano wrote:
>
> > My understanding of the situation after your patch (disregarding
> > the problem that prune and friends may happily break the logs
> > for detached HEAD), is that if you say "git show HEAD@{...}",
> > while on a branch, it looks at the log of the current branch but
> > while on a detached HEAD it shows the log from .git/logs/HEAD.
> > I have a feeling that this would be confusing.
>
> It would indeed. But that's not exactly what's happening.Well... It is a mess. That's not what's happening for git-log obviously, but what you describe is indeed the case for git-rev-parse.
There needs to be a dwim_reflog() function that looks for a matching reflog file by itself instead of using dwim_ref() and simply prefixing the resolved ref with "logs/". Unfortunately this tackling of reflog path built on top of resolve_ref() seems to be a popular assumption and chasing and fixing all those cases properly would require more time than I can spare right now.
Nicolas