This avoids duplicating this rune (so the manpage can't get out of
date).
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
set -e
. tests/lib
-t-dependencies sbuild
+t-dependencies sbuild man-db
t-restrict x-dgit-schroot-build
t-tstunt-parsechangelog
t-prep-newpackage example 1.1
+buildrune=$(
+ (export LC_ALL=C.UTF-8
+ if [ "$DGIT_TEST_INTREE" ]; then
+ make -C $DGIT_TEST_INTREE dgit-user.7.view
+ else
+ man 7 dgit-user
+ fi) | \
+ perl -ne '
+ next unless m/^ +Using sbuild$/ .. 0;
+ next unless m/^ +\%/ .. 0;
+ next if !m/\S/ .. 0;
+ s/^ +\%//;
+ print or die $!;
+ '
+)
+
cd $p
build () {
- git clean -xdf
- sbuild -c build -A --no-clean-source \
- --dpkg-source-opts='-Zgzip -z1 --format=1.0 -sn'
+ eval "$buildrune"
}
git checkout quilt-tip-1.1~0