about summary refs log tree commit diff
diff options
context:
space:
mode:
authorPol Dellaiera <pol.dellaiera@protonmail.com>2023-12-06 11:46:24 +0100
committergithub-actions[bot] <github-actions[bot]@users.noreply.github.com>2024-05-02 16:13:34 +0000
commit095af042d00dcdfb4b57f2237dd7bf9f61c565b9 (patch)
tree1420fd28141e1724afd6e69db79b73998b5f7ded
parent8636bdfa2f91bcb7be71744484a8b75d985aa92a (diff)
build-support/php: prevent the creation of symlinks of `bin` ending with `.bat`
(cherry picked from commit f59d1cf6d6494900826bf80fa6dd7547d51e75d3)
-rw-r--r--pkgs/build-support/php/hooks/composer-install-hook.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkgs/build-support/php/hooks/composer-install-hook.sh b/pkgs/build-support/php/hooks/composer-install-hook.sh
index e865ae116be2b..edba0e5eec4e6 100644
--- a/pkgs/build-support/php/hooks/composer-install-hook.sh
+++ b/pkgs/build-support/php/hooks/composer-install-hook.sh
@@ -116,7 +116,7 @@ composerInstallInstallHook() {
     cp -r . "$out"/share/php/"${pname}"/
 
     # Create symlinks for the binaries.
-    jq -r -c 'try .bin[]' composer.json | while read -r bin; do
+    jq -r -c 'try (.bin[] | select(test(".bat$")? | not) )' composer.json | while read -r bin; do
         mkdir -p "$out"/share/php/"${pname}" "$out"/bin
         makeWrapper "$out"/share/php/"${pname}"/"$bin" "$out"/bin/"$(basename "$bin")"
     done