Git development
 help / color / mirror / Atom feed
From: Junio C Hamano <junkio@cox.net>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: git@vger.kernel.org, junkio@cox.net
Subject: Re: [PATCH] object name: introduce ':::<oneline prefix>' notation
Date: Fri, 23 Feb 2007 17:18:42 -0800	[thread overview]
Message-ID: <7vzm741hfx.fsf@assigned-by-dhcp.cox.net> (raw)
In-Reply-To: <Pine.LNX.4.63.0702232347310.22628@wbgn013.biozentrum.uni-wuerzburg.de> (Johannes Schindelin's message of "Fri, 23 Feb 2007 23:48:38 +0100 (CET)")

Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:

> On Fri, 23 Feb 2007, Johannes Schindelin wrote:
>
>> To name a commit, you can now say
>> 
>> 	git rev-parse ':::Initial revision of "git"'
>
> Alex Riesen and Shawn Pearce suggested ":/" instead of ":::", to reflect 
> the searching nature ("/" is the key to search in "less" output).
>
> Comments?

Sounds good.  "git show :/path" does not currently mean "find
/path in the index", so I do not see offhand it would interfere
with anything.

However, it would be worthwhile to plant an escape hatch for
future extension.  Using short-and-sweet ":/" for the most
common case such as exact prefix match would be fine, but we
might want to say:

	':/!' syntax is reserved for future extension and does
	not look for a string that begins with "!".
	one extension "do not do anything special" is defined
	and is spelled as "!!" - so if you want to look for a
	commit that begins with "!something", please spell it
	as ':/!!something'

or something like that.

Obvious extension possibilities include:

	":/!(r=regexp)"
        ":/!(a=author)"
	":/!(d=2001-09-17)"
	":/!(p=Documentation/)"

or various combination of them e.g.

	":!(p=Documentation/)!(a=Johannes)Update command list"

to look for a commit by Johannes that touches Documentation/
area and oneline begins with "Update command list".

By the way, where do you start digging from?  From all refs?

  parent reply	other threads:[~2007-02-24  1:18 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-23 18:32 [PATCH] object name: introduce ':::<oneline prefix>' notation Johannes Schindelin
2007-02-23 22:48 ` Johannes Schindelin
2007-02-24  1:12   ` Jeff King
2007-02-24  1:21     ` Johannes Schindelin
2007-02-24  1:30       ` Jeff King
2007-02-24  1:49         ` Johannes Schindelin
2007-02-24  1:57           ` Jeff King
2007-02-24  2:14             ` Johannes Schindelin
2007-02-24  2:15               ` Jeff King
2007-02-24  1:53         ` Nicolas Pitre
2007-02-24  1:18   ` Junio C Hamano [this message]
2007-02-24  1:35     ` Johannes Schindelin
2007-02-24  1:46       ` Junio C Hamano
2007-02-24  1:56         ` Nicolas Pitre
2007-02-24  2:10           ` Johannes Schindelin

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=7vzm741hfx.fsf@assigned-by-dhcp.cox.net \
    --to=junkio@cox.net \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    /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