]> git.cameronkatri.com Git - tsssave.git/commitdiff
Use new beta directory structure main
authorCameron Katri <me@cameronkatri.com>
Mon, 18 Oct 2021 03:02:55 +0000 (23:02 -0400)
committerCameron Katri <me@cameronkatri.com>
Mon, 18 Oct 2021 03:02:55 +0000 (23:02 -0400)
tsssave

diff --git a/tsssave b/tsssave
index accccf288e7ed573721eb28abb8a0f8dfefffdf4..cae16f79a89b65e7540123f4881fb5eb0e13ea6b 100755 (executable)
--- a/tsssave
+++ b/tsssave
@@ -76,15 +76,15 @@ for device in $(yq e '.devices | keys | .[]' ${config}); do
        # BETA VERSIONS
        
        for signed in $(curl -sL https://api.m1sta.xyz/betas/${deviceid} | jq -re '.[] | select(.signed == true) | .buildid'); do
-               version="$(curl -s https://api.m1sta.xyz/betas/${deviceid} | jq -re ".[] | select(.buildid == \"${signed}\") | .version")"
-               if [ -e ${output}/${device}/${version}/beta/$(printf "%d\n" ${ecid})_${deviceid}_$(printf "${board}\n" | tr '[A-Z]' '[a-z]')_*-${signed}_*.shsh2 ]; then
+               version="$(curl -s https://api.m1sta.xyz/betas/${deviceid} | jq -re ".[] | select(.buildid == \"${signed}\") | .version" | sed 's/ /-/g')"
+               if [ -e ${output}/${device}/${version}/$(printf "%d\n" ${ecid})_${deviceid}_$(printf "${board}\n" | tr '[A-Z]' '[a-z]')_*-${signed}_*.shsh2 ]; then
                        printf "Skipping %s...\n" ${signed}
                else
                        printf "Saving %s...\n" ${signed}
                        pzb "$(curl -sL https://api.m1sta.xyz/betas/${deviceid} | jq -re ".[] | select(.buildid == \"${signed}\") | .url")" -g BuildManifest.plist -o BuildManifest-${board}-${signed}.plist
-                       mkdir -p ${output}/${device}/${version}/beta/
+                       mkdir -p ${output}/${device}/${version}/
                        tsschecker -d "${deviceid}" -B "${board}" -m /tmp/BuildManifest-${board}-${signed}.plist -s -e "${ecid}" --generator "${generator}" \
-                               --apnonce "${apnonce}" --save-path ${output}/${device}/${version}/beta/
+                               --apnonce "${apnonce}" --save-path ${output}/${device}/${version}/
                fi
        done
 done