diff --git a/check.sh b/check.sh index 313abaa..a5aa1be 100755 --- a/check.sh +++ b/check.sh @@ -1,25 +1,15 @@ #!/bin/bash set -e -echo "$1" -echo "$2" CHECK=$( echo -n "$2" | sed -e "s#$1:##g" | jq -R -s 'split("\n")' ) - -echo $CHECK - EXISTING=$( skopeo list-tags docker://$1 || echo '{"Tags":[]}' ) - -echo $EXISTING - TAGS=$( jq '.check - .existing.Tags' <<< "{\"check\": $CHECK, \"existing\": $EXISTING}" ) -echo $TAGS - echo $TAGS | jq '"Tag not found: "+ .[]' RESULT=$(echo $TAGS | jq '.==[]') if "$RESULT" == "true" then - echo "All images found" + echo "All tags found" fi echo exist=$RESULT >> $GITHUB_OUTPUT