mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-10-05 18:50:09 +02:00
Merge branch 'master' into 'master'
fix bugs in run-tests scripts This fixes a couple of subtle bugs in `./run-tests` that only showed up recently. See merge request !30
This commit is contained in:
commit
b2f4aa31fe
@ -10,7 +10,7 @@ echo_header() {
|
||||
|
||||
copy_apks_into_repo() {
|
||||
set +x
|
||||
for f in `find $APKDIR -name '*.apk' | grep -F -v -e unaligned -e unsigned`; do
|
||||
for f in `find $APKDIR -name '*.apk' | grep -F -v -e unaligned -e unsigned -e badsig -e badcert`; do
|
||||
name=$(basename $(dirname `dirname $f`))
|
||||
apk=`$aapt dump badging "$f" | sed -n "s,^package: name='\(.*\)' versionCode='\([0-9][0-9]*\)' .*,\1_\2.apk,p"`
|
||||
test $f -nt repo/$apk && rm -f repo/$apk # delete existing if $f is newer
|
||||
@ -46,19 +46,19 @@ create_test_file() {
|
||||
#------------------------------------------------------------------------------#
|
||||
# "main"
|
||||
|
||||
if [ $1 = "-h" ] || [ $1 = "--help" ]; then
|
||||
if [ "$1" = "-h" ] || [ "$1" = "--help" ]; then
|
||||
set +x
|
||||
echo "Usage: $0 '/path/to/folder/with/apks'"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z $ANDROID_HOME ]; then
|
||||
if [ -z "$ANDROID_HOME" ]; then
|
||||
echo "ANDROID_HOME must be set with the path to the Android SDK, i.e.: "
|
||||
echo " export ANDROID_HOME=/opt/android-sdk"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z $1 ]; then
|
||||
if [ -z "$1" ]; then
|
||||
APKDIR=`pwd`
|
||||
else
|
||||
APKDIR=$1
|
||||
|
Loading…
Reference in New Issue
Block a user