Clean bpo files if last sbuild-update run failed
authorChristoph Berg <myon@debian.org>
Mon, 18 Jul 2016 11:29:37 +0000 (13:29 +0200)
committerChristoph Berg <myon@debian.org>
Mon, 18 Jul 2016 11:30:05 +0000 (13:30 +0200)
jenkins/sbuild-update.sh

index 75e6d73d5a46c2e0435a50273d172bfbf188b975..9dd0b978542d0f239b392ecf69d724261d0f6e9b 100755 (executable)
@@ -81,6 +81,7 @@ umask 002
        if [ "${BACKPORTS:-}" ]; then
          echo "${BACKPORTS:-}" > /etc/apt/sources.list.d/backports.list
          if [ -d /var/lib/apt/backports ]; then
+           rm -f /var/lib/apt/lists/*backports* # clean up if last run failed
            cp -al /var/lib/apt/backports/* /var/lib/apt/lists
          fi
        fi