mirror of
https://github.com/openwrt/packages.git
synced 2025-12-21 19:14:30 +04:00
ci: avoid subshell invocation on APK version check
Use return code instead of scraping the stdio of `apk version --check`. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
This commit is contained in:
committed by
Rosen Penev
parent
af2e481894
commit
0455db48ff
@@ -55,7 +55,8 @@ jobs:
|
||||
fi
|
||||
PKG_VERSION=$(grep -E '^PKG_VERSION' "$ROOT/Makefile" | cut -f 2 -d '=')
|
||||
if [ -n "$PKG_VERSION" ]; then
|
||||
if [[ -n $($GITHUB_WORKSPACE/apk version --check "$PKG_VERSION") ]]; then
|
||||
$GITHUB_WORKSPACE/apk version --quiet --check "$PKG_VERSION"
|
||||
if [[ "$?" -gt "0" ]]; then
|
||||
echo "PKG_VERSION is not compatible: $PKG_VERSION"
|
||||
INCOMPATIBLE_VERSION+=" $ROOT"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user