git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Felipe Contreras <felipe.contreras@gmail.com>
To: Ramkumar Ramachandra <artagnon@gmail.com>
Cc: Junio C Hamano <gitster@pobox.com>,
	Duy Nguyen <pclouds@gmail.com>, Thomas Rast <trast@inf.ethz.ch>,
	Git List <git@vger.kernel.org>,
	Michael Haggerty <mhagger@alum.mit.edu>
Subject: Re: [PATCH] refs.c: interpret @ as HEAD
Date: Tue, 30 Apr 2013 17:00:34 -0500	[thread overview]
Message-ID: <CAMP44s1LJg9kcBVMb8YxJDTEpKerJoN5td7276=JB7ZY6APpZw@mail.gmail.com> (raw)
In-Reply-To: <CALkWK0kcuaXTKbafmC72C3H+UZN6oeEY140T21LJUHveO=UBvA@mail.gmail.com>

On Tue, Apr 30, 2013 at 1:22 PM, Ramkumar Ramachandra
<artagnon@gmail.com> 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

      parent reply	other threads:[~2013-04-30 22:00 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-30 12:24 [PATCH] refs.c: interpret @ as HEAD Ramkumar Ramachandra
2013-04-30 12:31 ` Duy Nguyen
2013-04-30 13:01 ` Thomas Rast
2013-04-30 13:32   ` Ramkumar Ramachandra
2013-04-30 15:04   ` Duy Nguyen
2013-04-30 16:08     ` Michael Haggerty
2013-04-30 16:09     ` Junio C Hamano
2013-04-30 16:26       ` Duy Nguyen
2013-04-30 17:15         ` Ramkumar Ramachandra
2013-05-01  2:18           ` Duy Nguyen
2013-05-01  8:35             ` Thomas Rast
2013-04-30 17:07       ` Ramkumar Ramachandra
2013-04-30 17:23       ` Ramkumar Ramachandra
2013-04-30 17:28         ` Felipe Contreras
2013-04-30 17:32           ` Ramkumar Ramachandra
2013-04-30 18:08             ` Junio C Hamano
2013-04-30 18:22               ` Ramkumar Ramachandra
2013-04-30 18:24                 ` Ramkumar Ramachandra
2013-04-30 18:40                 ` Ramkumar Ramachandra
2013-04-30 18:50                   ` Ramkumar Ramachandra
2013-04-30 22:00                 ` Felipe Contreras [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAMP44s1LJg9kcBVMb8YxJDTEpKerJoN5td7276=JB7ZY6APpZw@mail.gmail.com' \
    --to=felipe.contreras@gmail.com \
    --cc=artagnon@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=mhagger@alum.mit.edu \
    --cc=pclouds@gmail.com \
    --cc=trast@inf.ethz.ch \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).