From 7b76fc1ec543b3839186a9f11a0c62243bd7d2bd Mon Sep 17 00:00:00 2001 From: Shivam Mathur Date: Sat, 18 Jan 2025 02:22:55 +0530 Subject: [PATCH] Fix sed for macos in patch script --- src/scripts/extensions/patches/common.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/scripts/extensions/patches/common.sh b/src/scripts/extensions/patches/common.sh index 3aab5e01..28e8f000 100644 --- a/src/scripts/extensions/patches/common.sh +++ b/src/scripts/extensions/patches/common.sh @@ -1,7 +1,7 @@ process_file() { local file=$1 - sed -i '0,/#include.*\(php_lcg.h\|php_mt_rand.h\|php_rand.h\|standard\/php_random\.h\).*/s//\#include /' "$file" - sed -i '/#include.*\(php_lcg.h\|php_mt_rand.h\|php_rand.h\|standard\/php_random\.h\)/d' "$file" + sed -i'' -e '0,/#include.*\(php_lcg.h\|php_mt_rand.h\|php_rand.h\|standard\/php_random\.h\).*/s//\#include /' "$file" + sed -i'' -e '/#include.*\(php_lcg.h\|php_mt_rand.h\|php_rand.h\|standard\/php_random\.h\)/d' "$file" } export -f process_file