On 02/25/2012 10:30 AM, Michał Kiedrowicz wrote:
Michał Kiedrowicz<michal.kiedrowicz@xxxxxxxxx> wrote:
When `git-grep` is run with -P/--perl-regexp, it doesn't match ^ and $ at
the beginning/end of the line. This is because PCRE normally matches ^
and $ at the beginning/end of the whole text, not for each line, and git-grep
firstly passes a large chunk of text (possibly containing many lines) to
pcre_exec() before it splits the text into lines. This makes `git-grep -P`
behave differently from `git-grep -E` and also from `grep -P` and `pcregrep`:
Thanks! I can confirm that I now get the expected output.
Zbyszek
Original report:
http://permalink.gmane.org/gmane.comp.version-control.git/190830
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html