Subject: Re: [RFC PATCH 05/21] t3404: work around platform-specific behaviour on macOS 10.15

From: Junio C Hamano <[email-masked]>
Date: Thu, 03 Oct 2024 16:19:07 -0700

Eric Sunshine <[email-masked]> writes:

>> I suspect that the problem is that we use "\t" which is non-standard
>> rather than a literal tab character in the sed expression.
>
> Ah yes. The `sed` on macOS 10.15 would have been of an older
> BSD-lineage than the more modern macOS versions, so that makes sense.
> It wouldn't be a bad idea for the commit message to mention something
> along those lines.
>
> (I always use literal TAB with `sed` for this precise reason, which
> may explain why my eyes skipped right over the non-standard use of
> "\t" or I just wasn't paying close enough attention, which is equally
> likely.)

I also learned sed with old BSD behaviour to be portable (I somehow
thought it is not just "old BSD" but outside POSIX if you used "\t"
and friends).  Checking with

$ git grep 'sed.*\\t' t/\*.sh

shows that t3305 also has this problem.  The ones in t3404 are from
4611884e (sequencer: notify user of --update-refs activity,
2022-07-19), while the other one is from e1c52539 (t3305: check
notes fanout more carefully and robustly, 2020-02-03), both are
relatively old.  If people are not reporting issues, it may be an
indication that sed implementations of BSD origin may have died off.