]> Frank Brehm's Git Trees - profitbricks/jenkins-build-scripts.git/commitdiff
.pbuilderrc: Do not add the feature branch repo if it does not exists yet.
authorBenjamin Drung <benjamin.drung@profitbricks.com>
Mon, 14 Apr 2014 08:01:29 +0000 (10:01 +0200)
committerBenjamin Drung <benjamin.drung@profitbricks.com>
Mon, 14 Apr 2014 08:01:29 +0000 (10:01 +0200)
.pbuilderrc

index d992ef8f1c9a26ab1e4e0c9a4ac3a2512952ac37..4cb1228c4438289e7a054d204e4b03c758b3d116 100644 (file)
@@ -98,7 +98,11 @@ else
                 OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/debian-mirror profitbricks-backports-proposed-updates main contrib non-free |"
                 OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/debian-mirror profitbricks-backports-pre-staging main contrib non-free |"
                 OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/debian-mirror profitbricks-backports-experimental main contrib non-free |"
-                OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/dev-squeeze $PB_SUITE main contrib non-free |"
+                if wget -q --spider "http://alexandria.pb.local/dev-squeeze/dists/$PB_SUITE/Release"; then
+                    # Only add the dev-* repository if it already exist
+                    # It will not exist for the first package that targets this repository.
+                    OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/dev-squeeze $PB_SUITE main contrib non-free |"
+                fi
         else
                 BASETGZ="/var/cache/pbuilder/$NAME-$PB_SUITE-base.tgz"
                 BASEPATH="/var/cache/pbuilder/$NAME-$PB_SUITE-base.cow"