From 5194e08fa11bc79fc9291de7fd5d14b8ab0d3721 Mon Sep 17 00:00:00 2001 From: Ryan Carsten Schmidt Date: Wed, 7 Aug 2024 16:20:38 -0500 Subject: [PATCH] windowmaker: Use a single reinplace instead of three Also expand the list instead of using a foreach loop and suppress warnings when reinplace didn't change anything. --- x11/windowmaker/Portfile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/x11/windowmaker/Portfile b/x11/windowmaker/Portfile index 4dcaff6ff61bf..ef2259dd7c650 100644 --- a/x11/windowmaker/Portfile +++ b/x11/windowmaker/Portfile @@ -48,11 +48,7 @@ post-patch { set fl [glob -directory ${worksrcpath} WindowMaker/*menu*] lappend fl ${worksrcpath}/WindowMaker/Defaults/WindowMaker.in \ ${worksrcpath}/WPrefs.app/Menu.c ${worksrcpath}/WPrefs.app/Paths.c - foreach i $fl { - reinplace "s|/usr/share|${prefix}/share|g" $i - reinplace "s|/usr/local/share|${prefix}/share|g" $i - reinplace "s|/opt/kde2/share|${prefix}/share|g" $i - } + reinplace -E -q "s,(/usr|/usr/local|/opt/kde2)/share,${prefix}/share,g" {*}${fl} } configure.env-append \