Re: [PATCH v2 0/2] scripts/config: Use ERE (-E) and in-place editing (-i) in sed portably

Nicolas Schier <[email protected]> Fri, 24 Jul 2026 07:11:38 +0200
Newsgroups org.kernel.vger.linux-kbuild,org.kernel.vger.linux-kernel
Message-ID <178486989881.1795696.1026826281219622287.b4-ty@b4>
On Wed, 22 Jul 2026 01:50:47 +0800, Rong Zhang wrote:
> scripts/config: Use ERE (-E) and in-place editing (-i) in sed portably
> 
> The use of Extended Regular Expressions and in-place editing was removed
> by commit 83e8b90e1d2c ("scripts/config: use sed's POSIX interface").
> 
> Before that, the script used `-r' to enable ERE, which is indeed
> non-portable. However, POSIX.1-2024 [1][2] has accepted `-E' as a
> standard option to use ERE for matching, and major sed implementations
> (GNU, FreeBSD, OpenBSD, NetBSD, macOS) have supported `-E' for over two
> decades, so it makes no sense to use Basic Regular Expressions any more.
> Hence, we can safely take the advantage of ERE and merge chained calls
> to sed.
> 
> [...]

Applied to kbuild/linux.git (kbuild-next-unstable), thanks!

[1/2] scripts/config: Use POSIX standard ERE (-E) in sed
      https://git.kernel.org/kbuild/c/1d553517
[2/2] scripts/config: Use in-place editing (-i) in sed portably
      https://git.kernel.org/kbuild/c/005d6382

Please look out for regression or issue reports or other follow up
comments, as they may result in the patch/series getting dropped,
reverted or modified (e.g. trailers).

Patches applied to the kbuild-next-unstable branch are accepted pending
wider testing in linux-next and any post-commit review; they will
generally be moved to the kbuild-next branch in about a week if no
issues are found.

Best regards,
-- 
Nicolas