#!/bin/bash | |
while read -r device version; do | |
board=$(curl -s https://api.ipsw.me/v2.1/firmwares.json | jq -r ".devices[\"$device\"].BoardConfig") | |
tsschecker -d "$device" -B "$board" -i "$version" | |
if (( $? == 1 )); then | |
if [[ ${device,,} == iphone* ]]; then | |
os=iOS | |
elif [[ ${device,,} == ipad* ]]; then | |
os=iPadOS | |
elif [[ ${device,,} == appletv* ]]; then | |
os=tvOS | |
fi | |
curl -fsSL -X POST https://api.pushover.net/1/messages.json -d "token=$PUSHOVER_TOKEN" -d "user=$PUSHOVER_USER" -d 'title=TSS Signing Status' -d "message=$os $version is no longer being signed" -d 'priority=1' || exit | |
sed -r -i "/$device\\s+$version/d" versions.txt | |
fi | |
done < versions.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment