lbry-android-sdk/release.sh

17 lines
873 B
Bash
Raw Normal View History

2019-03-26 15:08:50 +01:00
#!/bin/bash
2018-04-24 22:01:11 +02:00
cd app
react-native bundle --platform android --dev false --entry-file src/index.js --bundle-output ../src/main/assets/index.android.bundle --assets-dest ../src/main/res/
cd ..
cp src/main/assets/index.android.bundle /dev/null
2018-04-24 22:01:11 +02:00
version=$(cat src/main/python/main.py | grep --color=never -oP '([0-9]+\.?)+')
2019-03-26 15:08:50 +01:00
buildozer android release <<< y
2018-04-24 22:01:11 +02:00
jarsigner -verbose -sigalg SHA1withRSA \
-digestalg SHA1 \
-keystore lbry-android.keystore \
2018-04-24 22:01:11 +02:00
-storepass $KEYSTORE_PASSWORD \
bin/browser-$version-release-unsigned.apk lbry-android > /dev/null \
2018-04-24 22:01:11 +02:00
&& mv bin/browser-$version-release-unsigned.apk bin/browser-$version-release-signed.apk
~/.buildozer/android/platform/android-sdk-23/build-tools/28.0.3/zipalign -v 4 \
bin/browser-$version-release-signed.apk bin/browser-$version-release.apk > /dev/null \
2018-04-24 22:01:11 +02:00
&& rm bin/browser-$version-release-signed.apk