php8: adapt test.sh for upcoming opkg -> apk transition
We used to rely on opkg to install the CLI tool for testing PHP modules, but when opkg is not available anymore, we have to use apk. The (simple) switch logic assumes, that only one of both package manager tools is installed. Signed-off-by: Michael Heimpold <mhei@heimpold.de>
This commit is contained in:
parent
8d999cfc50
commit
f21bc7f170
|
@ -14,7 +14,11 @@ case "$1" in
|
||||||
PHP_MOD="${1#php8-mod-}"
|
PHP_MOD="${1#php8-mod-}"
|
||||||
PHP_MOD="${PHP_MOD//-/_}"
|
PHP_MOD="${PHP_MOD//-/_}"
|
||||||
|
|
||||||
opkg install php8-cli
|
if command -v opkg >/dev/null 2>&1; then
|
||||||
|
opkg install php8-cli
|
||||||
|
else
|
||||||
|
apk add php8-cli
|
||||||
|
fi
|
||||||
|
|
||||||
php8-cli -m | grep -i "$PHP_MOD"
|
php8-cli -m | grep -i "$PHP_MOD"
|
||||||
;;
|
;;
|
||||||
|
|
Loading…
Reference in New Issue