mirror of
https://github.com/ImranR98/Obtainium.git
synced 2025-07-13 13:26:43 +02:00
Update build script to create zips
This commit is contained in:
18
build.sh
18
build.sh
@ -1,8 +1,18 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# Convenience script
|
# Convenience script
|
||||||
|
|
||||||
git fetch && git merge origin/main && git push; # Typically run after a PR to main, so bring dev up to date
|
CURR_DIR="$(pwd)"
|
||||||
rm ./build/app/outputs/flutter-apk/* 2>/dev/null; # Get rid of older builds if any
|
trap "cd "$CURR_DIR"" EXIT
|
||||||
flutter build apk && flutter build apk --split-per-abi # Build (both split and combined APKs)
|
|
||||||
|
git fetch && git merge origin/main && git push # Typically run after a PR to main, so bring dev up to date
|
||||||
|
rm ./build/app/outputs/flutter-apk/* 2>/dev/null # Get rid of older builds if any
|
||||||
|
flutter build apk && flutter build apk --split-per-abi # Build (both split and combined APKs)
|
||||||
for file in ./build/app/outputs/flutter-apk/*.sha1; do gpg --sign --detach-sig "$file"; done # Generate PGP signatures
|
for file in ./build/app/outputs/flutter-apk/*.sha1; do gpg --sign --detach-sig "$file"; done # Generate PGP signatures
|
||||||
rsync -r ./build/app/outputs/flutter-apk/ ~/Downloads/Obtainium-build/ # Dropoff in Downloads to allow for drag-drop into Flatpak Firefox
|
rsync -r ./build/app/outputs/flutter-apk/ ~/Downloads/Obtainium-build/ # Dropoff in Downloads to allow for drag-drop into Flatpak Firefox
|
||||||
|
cd ~/Downloads/Obtainium-build/ # Make zips just in case (for in-comment uploads)
|
||||||
|
for apk in *.apk; do
|
||||||
|
PREFIX="$(echo "$apk" | head -c -5)"
|
||||||
|
zip "$PREFIX" "$PREFIX"*
|
||||||
|
done
|
||||||
|
mkdir -p zips
|
||||||
|
mv *.zip zips/
|
||||||
|
Reference in New Issue
Block a user