summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMattia Rizzolo <mattia@mapreri.org>2015-04-04 23:59:08 +0200
committerHolger Levsen <holger@layer-acht.org>2015-04-05 14:45:32 +0200
commit1eb77335b1b55233388142956a20095596744b74 (patch)
treee47fb61b99d243611f5ea6026a9d8ea7b84c00e3
parent77837786ad7d9fbfb606703c3313f4f66456498b (diff)
downloadjenkins.debian.net-1eb77335b1b55233388142956a20095596744b74.tar.xz
reproducible: build: no real need to look up for a particular suite while SQL quering for a package to build
-rwxr-xr-xbin/reproducible_build.sh12
1 files changed, 1 insertions, 11 deletions
diff --git a/bin/reproducible_build.sh b/bin/reproducible_build.sh
index fe94cee6..f41a9614 100755
--- a/bin/reproducible_build.sh
+++ b/bin/reproducible_build.sh
@@ -165,17 +165,7 @@ TMPCFG=$(mktemp -t pbuilderrc_XXXX)
trap cleanup_all INT TERM EXIT
cd $TMPDIR
-SQL_SUITES=""
-for i in $SUITES ; do
- if [ -n "$SQL_SUITES" ] ; then
- SQL_SUITES="$SQL_SUITES, '$i'"
- else
- SQL_SUITES="('$i'"
- fi
-done
-SQL_SUITES="$SQL_SUITES)"
-
-RESULT=$(sqlite3 -init $INIT ${PACKAGES_DB} "SELECT s.suite, s.id, s.name, sch.date_scheduled, sch.save_artifacts FROM schedule AS sch JOIN sources AS s ON sch.package_id=s.id WHERE sch.date_build_started = '' AND s.suite IN $SQL_SUITES ORDER BY date_scheduled LIMIT 1")
+RESULT=$(sqlite3 -init $INIT ${PACKAGES_DB} "SELECT s.suite, s.id, s.name, sch.date_scheduled, sch.save_artifacts FROM schedule AS sch JOIN sources AS s ON sch.package_id=s.id WHERE sch.date_build_started = '' ORDER BY date_scheduled LIMIT 1")
if [ -z "$RESULT" ] ; then
echo "No packages scheduled, sleeping 30m."
sleep 30m