fix script for a gradle world

This commit is contained in:
Eric House 2017-09-07 07:45:33 -07:00
parent d87a1ca7a8
commit 2de54a2535

View file

@ -27,12 +27,15 @@ getPackage() {
echo $PACK
}
# FIXME: not all options require a working directory, e.g. --apk
WD=$(pwd)
while :; do
if [ -e ${WD}/AndroidManifest.xml -a -e ${WD}/build.xml ]; then
break
elif [ -e ${WD}/app/build.gradle ]; then
break
elif [ ${WD} = '/' ]; then
usage "reached / without finding AndroidManifest.xml"
usage "reached / without finding AndroidManifest.xml or build.gradle"
else
WD=$(cd $WD/.. && pwd)
fi