create_ota: don't check if APKs exist, script uses new tmpdir
Each time this script runs, it creates a new tmpdir and works in that. So
by definition, the working directory will be empty each time the script
runs. This makes this script a lot more readable.
diff --git a/create_ota.sh b/create_ota.sh
index 651fbca..e8a84d1 100755
--- a/create_ota.sh
+++ b/create_ota.sh
@@ -60,16 +60,16 @@
$TMP_DIR/FDroidPrivilegedExtension.apk
fi
else
- [ ! -f $TMP_DIR/$PRIVEXT_APK ] && curl -L https://f-droid.org/repo/$PRIVEXT_APK > $TMP_DIR/$PRIVEXT_APK
- [ ! -f $TMP_DIR/${PRIVEXT_APK}.asc ] && curl -L https://f-droid.org/repo/${PRIVEXT_APK}.asc > $TMP_DIR/${PRIVEXT_APK}.asc
+ curl -L https://f-droid.org/repo/$PRIVEXT_APK > $TMP_DIR/$PRIVEXT_APK
+ curl -L https://f-droid.org/repo/${PRIVEXT_APK}.asc > $TMP_DIR/${PRIVEXT_APK}.asc
$GPG --verify $TMP_DIR/${PRIVEXT_APK}.asc
rm $TMP_DIR/${PRIVEXT_APK}.asc
mv $TMP_DIR/$PRIVEXT_APK $TMP_DIR/FDroidPrivilegedExtension.apk
fi
# For both
-[ ! -f $TMP_DIR/$FDROID_APK ] && curl -L https://f-droid.org/repo/$FDROID_APK > $TMP_DIR/$FDROID_APK
-[ ! -f $TMP_DIR/${FDROID_APK}.asc ] && curl -L https://f-droid.org/repo/${FDROID_APK}.asc > $TMP_DIR/${FDROID_APK}.asc
+curl -L https://f-droid.org/repo/$FDROID_APK > $TMP_DIR/$FDROID_APK
+curl -L https://f-droid.org/repo/${FDROID_APK}.asc > $TMP_DIR/${FDROID_APK}.asc
$GPG --verify $TMP_DIR/${FDROID_APK}.asc
rm $TMP_DIR/${FDROID_APK}.asc
mv $TMP_DIR/$FDROID_APK $TMP_DIR/FDroid.apk