chiark / gitweb /
Test suite: tartree-edit: gitfetchinfo: Be a bit more careful
[dgit.git] / tests / tests / build-modes-sbuild
index 826c46734d87f3e194c4c92caf9ab83e6cc5a4d3..2a69ca98c7174e4abaa92b15de40082b1b99a065 100755 (executable)
@@ -15,16 +15,19 @@ after-hook () {
        # run.  We know it must be running it in the chroot because we
        # provide sbuild with the dsc, not the tree, so we simply
        # ignore all executions of the clean target by schroot.
-       sed '
-               s/^EXAMPLE RULES TARGET clean/HOOK SUPPRESSED &/;
-       ' ../example_1.0_$arch.build >>$bmlog
+       local sblog=../example_1.0_$arch.build
+       if [ -e $sblog ]; then
+               sed '
+                       s/^EXAMPLE RULES TARGET clean/HOOK SUPPRESSED &/;
+               ' <$sblog >>$bmlog
+       fi
 }
 bm_quirk_after_act=after-hook
 
 bm-prep
 
-act="sbuild -c build"
-real_act="$act --no-arch-all"
+act="sbuild -c build --no-arch-all"
+real_act="$act"
 
 e_source=true
 e_targets='build-arch binary-arch'