All of lore.kernel.org
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Peter Baumann <waste.manager@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: How to use path limiting (using a glob)?
Date: Wed, 11 Feb 2009 11:48:52 -0800	[thread overview]
Message-ID: <7v1vu4eouz.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <20090211191432.GC27232@m62s10.vlinux.de> (Peter Baumann's message of "Wed, 11 Feb 2009 20:14:32 +0100")

Peter Baumann <waste.manager@gmx.de> writes:

> after reading Junio's nice blog today where he explained how to use git grep
> efficiently, I saw him using a glob to match for the interesting files:
>
> 	 $ git grep -e ';;' -- '*.c'
>
> Is it possible to have the same feature in git diff and the revision
> machinery? Because I tried
>
> 	$ cd $path_to_your_git_src_dir
> 	$ git log master -p -- '*.h'
> 	.... No commit shown 
>
> 	$ git diff --name-only v1.5.0  v1.6.0 -- '*.c'
>
> and both don't return anything.

There was a recent discussion on this.  The index family uses glob, the
tree family uses leading-path only.  The one implemented for grep can do
both, and attempts to unify both by providing possibly reusable interface
so that the other two families can be ported to, but we haven't managed to
trick anybody to take up the task ;-).

  parent reply	other threads:[~2009-02-11 19:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-11 19:14 How to use path limiting (using a glob)? Peter Baumann
2009-02-11 19:40 ` Linus Torvalds
2009-02-12 10:27   ` Peter Baumann
2009-02-12 11:09     ` Sitaram Chamarty
2009-02-11 19:48 ` Junio C Hamano [this message]
2009-02-11 21:09   ` Nanako Shiraishi

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=7v1vu4eouz.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=waste.manager@gmx.de \
    /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.