diff options
-rwxr-xr-x | bin/reproducible_build.sh | 8 |
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) |