git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2] builtin-blame: Reencode commit messages according to git-log rules.

From
Junio C Hamano <gitster@pobox.com>
Date
Oct 22, 2008, 19:07 UTC
Message-ID
<7vd4hsv46z.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<20081022082016.GA18473@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 15 quoted lines
> On Wed, Oct 22, 2008 at 12:55:57AM +0400, Alexander Gavrilov wrote:
>
>> +test_expect_success \
>> +	'blame respects i18n.commitencoding' '
>> +	git blame --incremental file | \
>> +		grep "^\(author\|summary\) " > actual &&
>> +	test_cmp actual expected
>
> Even though it is POSIX, using backslashed grouping in 'grep' isn't
> portable. It fails at least on Solaris 8, and you have to do:
>
>   egrep "^(author|summary) "
>
> instead. Of course, I can't get your test to pass even with that change,
> but I think that is just a broken iconv on Solaris.

Yuck. Solaris 8 /usr/bin/grep does not even grok "-e", so we cannot do a more obvious:

	grep -e "^author " -e "^summary "
Do people build with NO_EXTERNAL_GREP on older Solaris?

git-submodule.sh uses grep "-e" to look for two patterns and I suspect older Solaris would have the same issue.

Previous: Jeff KingNext: Jeff King
Message 7 of 13 in “builtin-blame: Reencode commit messages according to git-log rules.”
  1. builtin-blame: Reencode commit messages according to git-log rules.Alexander Gavrilov, Oct 21, 2008
  2. Jeff KingOct 22, 2008
  3. Alexander GavrilovOct 22, 2008
  4. Jeff KingOct 22, 2008
  5. Alexander GavrilovOct 22, 2008
  6. Jeff KingOct 22, 2008
  7. Junio C HamanoOct 22, 2008
  8. Jeff KingOct 22, 2008
  9. Jeff KingOct 22, 2008
  10. Johannes SchindelinOct 22, 2008
  11. Jeff KingOct 22, 2008
  12. Jakub NarebskiOct 22, 2008
  13. Jeff KingOct 22, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.