Re: [PATCH 19/22] t/t8*: merge "grep | sed" pipelines
- From
Beat Bolli <dev+git@drbeat.li>
- Date
- Mar 6, 2024, 21:03 UTC
- Message-ID
- <6571138d-16b0-4c59-b6fe-a256b1c7e37a@drbeat.li>
- In-Reply-To
- <ZefSPAiTLrRVeXm6@pobox.com>
On 06.03.24 03:17, Todd Zullinger wrote:
Show 28 quoted lines
> Junio C Hamano wrote: >> Isn't -E a GNUism? >> >> At least, >> >> https://pubs.opengroup.org/onlinepubs/9699919799/utilities/sed.html >> >> does not seem to have it (we may need to fix t6030 to rid its only >> existing use). > > I _thought_ that -r was the GNUism. The GNU sed-4.8 manpage > says: > > -E, -r, --regexp-extended > use extended regular expressions in the script > (for portability use POSIX -E). > > That doesn't mean the man page is right, of course. :) > > https://www.austingroupbugs.net/view.php?id=528 suggests > that -E has been adopted and, importanly, is more widely > supported than -r (if we were considering using that rather > than rewriting this to not use ERE syntax). MacOS in > particular supports -E but not -r, according to that link. > > It seems like the documentation hasn't quite caught up to > reality yet, perhaps? >
At least macOS Ventura and later supports "sed -E". I can't say what the more exotic platforms (NonStop?) have.