Re: [PATCH 03/16] more tr portability test script fixes
- From
Alex Riesen <raa.lkml@gmail.com>
- Date
- Mar 18, 2008, 23:24 UTC
- Message-ID
- <20080318232453.GE3450@steel.home>
- In-Reply-To
- <20080318224436.GA6806@coredump.intra.peff.net>
Jeff King, Tue, Mar 18, 2008 23:44:37 +0100:
Show 18 quoted lines
> On Tue, Mar 18, 2008 at 11:23:02PM +0100, Alex Riesen wrote: > > > Jeff King, Wed, Mar 12, 2008 22:31:06 +0100: > > > - tr '\000' '\012' <"$1" | sed -e "$sanitize_diff_raw_z" >.tmp-1 > > > - tr '\000' '\012' <"$2" | sed -e "$sanitize_diff_raw_z" >.tmp-2 > > > + perl -pe 'y/\000/\012/' <"$1" | sed -e "$sanitize_diff_raw_z" >.tmp-1 > > > + perl -pe 'y/\000/\012/' <"$2" | sed -e "$sanitize_diff_raw_z" >.tmp-2 > > > > These break in presence of ActiveState Perl on Windows. > > > > I suggest replacing such simple construction with a simplified, > > in-tree, version of tr. > > <sigh> It's sad that it must come to that, but your test-tr patches seem > like the only sane choice. They seem to work fine on my Solaris box. > > Note that there are still a few uses of 'tr' in actual git scripts. > However, they are pretty tame, so I think they should work everywhere.
Yes, I thought about them too and hope for the same (they'll do).
> Otherwise, test-tr must become "git tr". :)
We already use "git diff" and "git apply" as reliable "diff" and "patch" :)