git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Michał Kiedrowicz" <michal.kiedrowicz@gmail.com>
Cc: git@vger.kernel.org, "Zbigniew Jędrzejewski-Szmek" <zbyszek@in.waw.pl>
Subject: Re: [PATCH] grep -P: Fix matching ^ and $
Date: Sun, 26 Feb 2012 14:39:29 -0800	[thread overview]
Message-ID: <7vlinpdxsu.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <1330161868-7954-1-git-send-email-michal.kiedrowicz@gmail.com> ("Michał Kiedrowicz"'s message of "Sat, 25 Feb 2012 10:24:28 +0100")

Michał Kiedrowicz <michal.kiedrowicz@gmail.com> writes:

> @@ -893,4 +900,20 @@ test_expect_success 'mimic ack-grep --group' '
>  	test_cmp expected actual
>  '
>  
> +cat >expected <<EOF
> +space: line with leading space1
> +space: line with leading space2
> +space: line with leading space3
> +EOF
> +
> +test_expect_success 'grep -E "^ "' '
> +	git grep -E "^ " space >actual &&
> +	test_cmp expected actual
> +'
> +
> +test_expect_success "grep -P '^ '" '
> +	git grep -P "^ " space >actual &&
> +	test_cmp expected actual
> +'

This test does not pass for me as I do not usually build with pcre;
shouldn't it be protected with some test prerequisite?

Otherwise the patch looks good; thanks.

  parent reply	other threads:[~2012-02-26 22:40 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-25  9:24 [PATCH] grep -P: Fix matching ^ and $ Michał Kiedrowicz
2012-02-25  9:30 ` Michał Kiedrowicz
2012-02-25 17:52   ` Zbigniew Jędrzejewski-Szmek
2012-02-26 22:39 ` Junio C Hamano [this message]
2012-02-27 16:45   ` [PATCH] grep -P: add tests for " Zbigniew Jędrzejewski-Szmek
2012-02-27 20:21     ` 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=7vlinpdxsu.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=michal.kiedrowicz@gmail.com \
    --cc=zbyszek@in.waw.pl \
    /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).