merge upstream
This commit is contained in:
26
.github/scripts/move-apks.sh
vendored
Normal file
26
.github/scripts/move-apks.sh
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
shopt -s globstar nullglob extglob
|
||||
|
||||
# Get APKs from previous jobs' artifacts
|
||||
cp -R ~/apk-artifacts/ $PWD
|
||||
APKS=( **/*".apk" )
|
||||
|
||||
# Fail if too little extensions seem to have been built
|
||||
if [ "${#APKS[@]}" -le "100" ]; then
|
||||
echo "Insufficient amount of APKs found. Please check the project configuration."
|
||||
exit 1
|
||||
else
|
||||
echo "Moving ${#APKS[@]} APKs"
|
||||
fi
|
||||
|
||||
DEST=$PWD/apk
|
||||
rm -rf $DEST && mkdir -p $DEST
|
||||
|
||||
for APK in ${APKS[@]}; do
|
||||
BASENAME=$(basename $APK)
|
||||
APKNAME="${BASENAME%%+(-release*)}.apk"
|
||||
APKDEST="$DEST/$APKNAME"
|
||||
|
||||
cp $APK $APKDEST
|
||||
done
|
Reference in New Issue
Block a user