Legacy-iOS-Kit/.github/workflows/build.yml
LukeZGD 3a05a09fc3 Verbose boot option for 3GS, and other changes
- 3GS verbose boot option is added, currently supported on iOS 4 and lower only
- unlist touch 3 3.1.x from being supported
- undo touch 3 3.1.3 "fix"
- undo touch 3 hacktivation test attempt
2024-07-18 21:34:43 +08:00

102 lines
4.2 KiB
YAML

name: Create zip files
on:
push:
branches:
- main
jobs:
create-zip-files:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Create name version env
run: |
sudo timedatectl set-timezone Asia/Singapore
echo "DATE=$(date +%y.%m)" >> $GITHUB_ENV
echo "COUNT=$(git rev-list --count HEAD --since=$(date --date="$(date +%Y-%m-01) - 1 second" +%s) | xargs printf "%02d")" >> $GITHUB_ENV
echo "SHA_SHORT=$(echo ${{ github.sha }} | cut -c -7)" >> $GITHUB_ENV
echo "DATE_OLD=$(date +%Y-%m-%d)" >> $GITHUB_ENV
- name: Create git hash and version
run: |
echo "${{ env.SHA_SHORT }}" | tee ./resources/git_hash
echo "v${{ env.DATE }}.${{ env.COUNT }}" | tee ./resources/version
- name: Download some files
run: |
mkdir saved
pushd resources
curl -L https://github.com/LukeZGD/ipwndfu/archive/d0f9b0faae98d042e17fbb47cedf342e983a6bb8.zip -o ipwndfu.zip
curl -L https://github.com/LukeZGD/Legacy-iOS-Kit-Keys/archive/refs/heads/master.zip -o keys.zip
unzip keys.zip -d .
unzip ipwndfu.zip -d .
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
popd
- name: Move linux binaries
run: |
mkdir -p ./exclude/bin
cp -R ./bin/* ./exclude/bin
rm -r ./bin/linux
- name: Zip macos files
run: zip -r ${{ github.event.repository.name }}_macos_v${{ env.DATE }}.${{ env.COUNT }}.zip bin/ LICENSE resources/ restore.sh README.md
- name: Move macos binaries
run: |
rm -r ./bin/macos
mkdir ./bin/linux
cp -R ./exclude/bin/linux/x86_64 ./bin/linux
- name: Zip linux files
run: zip -r ${{ github.event.repository.name }}_linux_x86_64_v${{ env.DATE }}.${{ env.COUNT }}.zip bin/ LICENSE resources/ restore.sh README.md
- name: Move linux binaries and other files
run: |
rm -r ./bin/linux/x86_64
cp -R ./exclude/bin/linux/arm64 ./bin/linux
- name: Zip linux arm64 files
run: zip -r ${{ github.event.repository.name }}_linux_arm64_v${{ env.DATE }}.${{ env.COUNT }}.zip bin/ LICENSE resources/ restore.sh README.md
- name: Move linux arm64 binaries and other files
run: |
rm -r ./bin/linux/arm64
cp -R ./exclude/bin/linux/armhf ./bin/linux
- name: Zip linux armhf files
run: zip -r ${{ github.event.repository.name }}_linux_armhf_v${{ env.DATE }}.${{ env.COUNT }}.zip bin/ LICENSE resources/ restore.sh README.md
- name: Move linux armhf binaries and other files
run: rm -r ./bin/linux
- name: Copy exclude files back
run: cp -R ./exclude/bin/* ./bin
- name: Zip complete files
run: zip -r ${{ github.event.repository.name }}_complete_v${{ env.DATE }}.${{ env.COUNT }}.zip bin/ LICENSE resources/ restore.cmd restore.sh README.md
- name: Create this file to get latest git hash
run: |
echo "This file is for version checking purposes only. Get the correct zip file for your platform in the release assets." > README.txt
zip -r git-hash_${{ env.DATE_OLD }}-${{ env.SHA_SHORT }}.zip README.txt
- name: Update latest release
uses: pyTooling/Actions/releaser@main
with:
tag: latest
rm: true
token: ${{ secrets.GITHUB_TOKEN }}
files: |
git-hash_${{ env.DATE_OLD }}-${{ env.SHA_SHORT }}.zip
${{ github.event.repository.name }}_complete_v${{ env.DATE }}.${{ env.COUNT }}.zip
${{ github.event.repository.name }}_macos_v${{ env.DATE }}.${{ env.COUNT }}.zip
${{ github.event.repository.name }}_linux_armhf_v${{ env.DATE }}.${{ env.COUNT }}.zip
${{ github.event.repository.name }}_linux_arm64_v${{ env.DATE }}.${{ env.COUNT }}.zip
${{ github.event.repository.name }}_linux_x86_64_v${{ env.DATE }}.${{ env.COUNT }}.zip