xwords/xwords4/android/scripts/build-debug.sh

43 lines
690 B
Bash
Raw Normal View History

#!/bin/bash
DIR=/tmp/build_$$_dir
mkdir -p $DIR
pushd $DIR
2024-01-05 11:21:58 -08:00
usage() {
[ $# -ge 1 ] && echo "Error: $1"
echo "builds debug variant from the current tip of github"
echo "(last modified Jan 2024)"
exit 1
}
while [ $# -ge 1 ]; do
case $1 in
--help)
usage
;;
*)
usage "unexpected command $1"
;;
esac
shift
done
git clone https://github.com/eehouse/xwords.git
cd xwords/xwords4/android
./gradlew asXw4dDeb
2024-01-05 11:21:58 -08:00
APK="$(find . -name '*.apk')"
if [ -n "${XW4D_UPLOAD}" ]; then
2024-02-08 11:42:18 -08:00
IFS=","
for UPPATH in ${XW4D_UPLOAD}; do
# scp "$APK" ${UPPATH}
echo "uploaded $APK to ${UPPATH}"
done
else
2024-01-05 11:21:58 -08:00
echo "not uploading $APK: XW4D_UPLOAD not set" >&2
fi
popd
rm -rf $DIR