summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2014-10-12 18:00:52 +0200
committerHolger Levsen <holger@layer-acht.org>2014-10-12 18:00:52 +0200
commit4792c4d6a600d2a50d20a02893095a0d17ef8b38 (patch)
tree3594116168460cb64ca385a471132470aad14a03 /bin
parentbf740f1577176466c19fb2d67bc5f6daf3b5b124 (diff)
downloadjenkins.debian.net-4792c4d6a600d2a50d20a02893095a0d17ef8b38.tar.xz
reproducible: refactor
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_build.sh8
1 files changed, 3 insertions, 5 deletions
diff --git a/bin/reproducible_build.sh b/bin/reproducible_build.sh
index d95bf4c0..1f5a357d 100755
--- a/bin/reproducible_build.sh
+++ b/bin/reproducible_build.sh
@@ -37,13 +37,11 @@ update_sources_table() {
if [ "$BET" = "" ] ; then
BET=$VERSION
continue
- elif dpkg --compare-versions "$BET" gt "$VERSION" ; then
- sqlite3 -init $INIT ${PACKAGES_DB} "DELETE FROM sources WHERE name = '$PKG' AND version = '$VERSION'"
- else
- sqlite3 -init $INIT ${PACKAGES_DB} "DELETE FROM sources WHERE name = '$PKG' AND version = '$BET'"
- BET=$VERSION
+ elif dpkg --compare-versions "$BET" lt "$VERSION" ; then
+ BET=$VERSION
fi
done
+ sqlite3 -init $INIT ${PACKAGES_DB} "DELETE FROM sources WHERE name = '$PKG' AND version != '$BET'"
done
echo "$(date) Done removing duplicate versions from sources db..."
# update amount of available packages (for doing statistics later)