fix build error 2

This commit is contained in:
t1amak
2025-12-10 02:14:34 +01:00
parent 9b7e0a80d6
commit 921f6a1219
3 changed files with 17 additions and 8 deletions

View File

@@ -8,8 +8,8 @@ if [ -z "$CHECKOUT_REF" ]; then
exit 1
fi
if ! git rev-parse --verify --quiet "$CHECKOUT_REF^{commit}" >/dev/null; then
echo "Requested ref '$CHECKOUT_REF' is not present in the build context."
exit 1
echo "Requested ref '$CHECKOUT_REF' is not present in the build context, falling back to HEAD."
CHECKOUT_REF=HEAD
fi
echo "Checking out ${CHECKOUT_REF} (version label $2)"
git checkout --detach "$CHECKOUT_REF"