From: "Shawn O. Pearce" <spearce@spearce.org>
To: Daniel Barkalow <barkalow@iabervon.org>
Cc: Junio C Hamano <junkio@cox.net>, git@vger.kernel.org
Subject: Re: [PATCH 0/3] Support config-based names
Date: Mon, 11 Jun 2007 23:31:34 -0400 [thread overview]
Message-ID: <20070612033134.GS6073@spearce.org> (raw)
In-Reply-To: <Pine.LNX.4.64.0706112244210.5848@iabervon.org>
Daniel Barkalow <barkalow@iabervon.org> wrote:
> It can be useful to refer to commits in remotes based on their configured
> relationship to local branches. For example, "git log HEAD^[push]..HEAD"
> would, when pushing is set up, show what hasn't been pushed yet.
Interesting.
What about `git diff master^[push]@{3.days.ago}^{tree} master` ?
Can anyone even understand that? Can Git even understand it?
As I follow your code I don't think it would, as the ^[push]
operator seems like it needs to be on the very end of the string,
and it assumes everything to the left of the ^[ is the branch name.
So I also couldn't phrase that as:
git diff master@{3.days.ago}^[push]^{tree} master
More interesting is just what do you want going on here with the
reflog query and the ^[push] query. Should the reflog operator apply
before the ^[push] translation, or after? Or should it depend on
the order of them in the statement? I can see where you would want
to look at your local tracking branch for the current branch 3 days
ago, which might be "HEAD^[push]@{3.days.ago}". But I'm not really
sure what the meaning of "HEAD@{3.days.ago}^[push]" is. Is that
the branch that HEAD was on 3 days ago's push branch? Huh? ;-)
Food for thought.
In general it seems our "operators" are ^{foo} or @{foo}, so I wonder
why not ^{push}. push is not a valid object type, and probably
never will be, so peeling the onion back to get to what ^{push}
means (even though its not an object type) is probably OK.
--
Shawn.
next prev parent reply other threads:[~2007-06-12 3:32 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-06-12 3:10 [PATCH 0/3] Support config-based names Daniel Barkalow
2007-06-12 3:31 ` Shawn O. Pearce [this message]
2007-06-12 4:13 ` Daniel Barkalow
2007-06-12 5:28 ` Junio C Hamano
2007-06-12 5:56 ` Daniel Barkalow
2007-06-12 6:44 ` Junio C Hamano
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=20070612033134.GS6073@spearce.org \
--to=spearce@spearce.org \
--cc=barkalow@iabervon.org \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.