From: Hans-Christoph Steiner Date: Mon, 19 Sep 2016 11:29:46 +0000 (+0200) Subject: buildserver: only include latest m2 when provisioning X-Git-Tag: 0.8~159^2 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=a2a630c83c87285ba95ada59810e5aae4a8dcb03;p=fdroidserver.git buildserver: only include latest m2 when provisioning I think the `android update sdk` tool is installing all of the m2 files that are present in the temp cache, and it seems to do it in order of newest to oldest. Well done, and I thought that tool couldn't get any worse. So only include the latest version of android_m2repository*.zip in the temp cache. --- diff --git a/buildserver/provision-android-sdk b/buildserver/provision-android-sdk index 946f1e70..7c9b3286 100644 --- a/buildserver/provision-android-sdk +++ b/buildserver/provision-android-sdk @@ -42,7 +42,8 @@ done cd /vagrant/cache # make links for `android update sdk` to use and delete -for f in android_*.zip android-[0-9]*.zip platform-[0-9]*.zip build-tools_r*-linux.zip; do +latestm2=`ls -1 android_m2repository*.zip | sort -n | tail -1` +for f in $latestm2 android-[0-9]*.zip platform-[0-9]*.zip build-tools_r*-linux.zip; do rm -f ${ANDROID_HOME}/temp/$f ln -s /vagrant/cache/$f ${ANDROID_HOME}/temp/ done