From 60b6d07f3acda2875e223ddd703157aa614b21ce Mon Sep 17 00:00:00 2001 From: LukeZGD <26163116+LukeZGD@users.noreply.github.com> Date: Thu, 18 Jul 2024 22:14:18 +0800 Subject: [PATCH] Fix ipwndfu updater --- .github/workflows/build.yml | 2 +- restore.sh | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 77c5a32..dcd0e40 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -35,7 +35,7 @@ jobs: cp -r Legacy-iOS-Kit-Keys-master/* firmware mv ipwndfu*/ ../saved/ipwndfu rm -rf Legacy-iOS-Kit-Keys-master/ ipwndfu.zip keys.zip - echo "8732b15c7262d68d2c5dd8cdbe0f6efb217d0240" > ../saved/ipwndfu/sha1 + echo "8732b15c7262d68d2c5dd8cdbe0f6efb217d0240" > ../saved/ipwndfu/sha1check popd - name: Move linux binaries diff --git a/restore.sh b/restore.sh index 9261a7a..ee5c69b 100755 --- a/restore.sh +++ b/restore.sh @@ -1697,12 +1697,13 @@ device_ipwndfu() { device_enter_mode DFU local ipwndfu_comm="d0f9b0faae98d042e17fbb47cedf342e983a6bb8" local ipwndfu_sha1="8732b15c7262d68d2c5dd8cdbe0f6efb217d0240" - if [[ ! -s ../saved/ipwndfu/ipwndfu || $(cat ../saved/ipwndfu/sha1) != "$ipwndfu_sha1" ]]; then + if [[ ! -s ../saved/ipwndfu/ipwndfu || $(cat ../saved/ipwndfu/sha1check) != "$ipwndfu_sha1" ]]; then rm -rf ../saved/ipwndfu-* download_file https://github.com/LukeZGD/ipwndfu/archive/$ipwndfu_comm.zip ipwndfu.zip $ipwndfu_sha1 unzip -q ipwndfu.zip -d ../saved - mv ../saved/ipwndfu-*/* ../saved/ipwndfu - echo "$ipwndfu_sha1" > ../saved/ipwndfu/sha1 + rm -rf ../saved/ipwndfu + mv ../saved/ipwndfu-* ../saved/ipwndfu + echo "$ipwndfu_sha1" > ../saved/ipwndfu/sha1check rm -rf ../saved/ipwndfu-* fi if [[ $platform == "macos" ]]; then