git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "George Spelvin" <linux@horizon.com>
To: gitster@pobox.com, azure@iki.fi
Cc: linux@horizon.com, git@vger.kernel.org
Subject: Re: fatal: git grep: cannot generate relative filenames containing '..'
Date: Sun, 18 Jan 2009 11:58:23 -0500	[thread overview]
Message-ID: <20090118165823.24501.qmail@science.horizon.com> (raw)
In-Reply-To: <83vdsefz9j.fsf@kalahari.s2.org>

Hannu Koivisto <azure@iki.fi> wrote:
> It turns out that this "entire git tree" is practically my only use
> case when using normal (find and) grep and when I first tried git
> grep, I actually expected it to do just that with no path specified.
>
> Why?  Because of the way at least git diff and git log work.  I
> thought that just like with them, "git grep foo" would search the
> entire git tree and I would have to say "git grep foo ." to limit to
> the current directory and its subdirectories.  git-grep(1)'s "Look
> for specified patterns in the working tree files..." at least
> didn't seem to disagree with my expectation so I was a bit puzzled.
>
> So I'd rather see git grep behave in a way consistent with git log
> and git diff (I realize that would change current behaviour instead
> of extending it).

D'oh.  You're completely right.  Space-dot is trivial to type if you
want the current directory only, and that is more consistent.

Could that be considered for 1.7?

  reply	other threads:[~2009-01-18 16:59 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-15 22:29 fatal: git grep: cannot generate relative filenames containing '..' George Spelvin
2009-01-15 23:04 ` Markus Heidelberg
2009-01-16  1:52 ` Junio C Hamano
2009-01-16 21:30   ` Jon Loeliger
2009-01-17  2:21   ` Hannu Koivisto
2009-01-18 16:58     ` George Spelvin [this message]
2009-01-16  2:07 ` Johannes Schindelin
2009-01-16  2:12   ` Junio C Hamano
2009-01-16  3:27     ` George Spelvin
2009-01-16  4:24       ` George Spelvin
2009-01-16 11:41       ` SZEDER Gábor

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=20090118165823.24501.qmail@science.horizon.com \
    --to=linux@horizon.com \
    --cc=azure@iki.fi \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    /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).