From: Felipe Contreras Date: Tue, 30 Apr 2013 22:00:34 GMT Subject: Re: [PATCH] refs.c: interpret @ as HEAD Message-ID: In-Reply-To: On Tue, Apr 30, 2013 at 1:22 PM, Ramkumar Ramachandra wrote: > Junio C Hamano wrote: >> @{-1}@{0} does. That means @{0} is a revision and not a ref, but @{-1} >> is. > > Right. I missed that. > >> '"@" given alone' has to be a ref if we want @@{5.minutes.ago} to >> resolve. > > Yeah, I just realized that it's a bug in the @{u} implementation. I don't think so. You probably need to modify branch_get(), because it has a special case for "HEAD", and who knows if it's hard-coded in other places. It's not just the @{u} implementation. If we do the magic at the rev-parsing phase, all these details become irrelevant. FTR. @@{upstream} and @@{now} works just fine in v2 of my patch series. -- Felipe Contreras