generated from osc/skins-template
Update .gitea/workflows/test-skins.yml
This commit is contained in:
@@ -77,10 +77,17 @@ jobs:
|
||||
|
||||
# Check if it's an external URL
|
||||
if [[ "$decoded_link" =~ ^https?:// ]]; then
|
||||
# Replace git.sulej.net with internal gitea URL for checking
|
||||
check_url="$link"
|
||||
if [[ "$link" =~ git\.sulej\.net ]]; then
|
||||
check_url="${link//git.sulej.net/gitea:3000}"
|
||||
check_url="${check_url//https:/http:}"
|
||||
fi
|
||||
|
||||
# Check external URL with curl
|
||||
http_code=$(curl -s -o /dev/null -w "%{http_code}" --max-time 10 \
|
||||
-H "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36" \
|
||||
"$link" 2>/dev/null || echo "000")
|
||||
"$check_url" 2>/dev/null || echo "000")
|
||||
|
||||
# Accept 2xx and 3xx status codes as valid
|
||||
if ! [[ "$http_code" =~ ^[23][0-9][0-9]$ ]]; then
|
||||
@@ -155,13 +162,13 @@ jobs:
|
||||
echo "skin: $skin_name"
|
||||
|
||||
# Download link
|
||||
grep "/export/$skin_name/.*\.osk" /tmp/download_$$.txt 2>/dev/null || true
|
||||
grep "/export/$skin_name/.*\.osk" /tmp/download_$$.txt 2>/dev/null | sort -u || true
|
||||
|
||||
# Thumbnail
|
||||
grep "thumbnail/$skin_name/" /tmp/media_$$.txt 2>/dev/null || true
|
||||
grep "thumbnail/$skin_name/" /tmp/media_$$.txt 2>/dev/null | sort -u || true
|
||||
|
||||
# Docs
|
||||
grep "/docs/$skin_name/" /tmp/tags_$$.txt 2>/dev/null || true
|
||||
grep "/docs/$skin_name/" /tmp/tags_$$.txt 2>/dev/null | sort -u || true
|
||||
|
||||
echo ""
|
||||
done < /tmp/skins_$$.txt
|
||||
|
||||
Reference in New Issue
Block a user