]> git.notmuchmail.org Git - notmuch/commitdiff
debian: return an error if debian snapshot build fails
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Wed, 4 Dec 2019 08:47:38 +0000 (03:47 -0500)
committerDavid Bremner <david@tethera.net>
Fri, 20 Dec 2019 23:54:11 +0000 (08:54 +0900)
Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
Makefile.local

index 7c12612dee8e806535be42f1381e3f24448f093b..586cdf7538690366f12d8c43585725ffaeff6c9b 100644 (file)
@@ -97,14 +97,16 @@ pre-release:
 .PHONY: debian-snapshot
 debian-snapshot:
        make VERSION=$(VERSION) clean
 .PHONY: debian-snapshot
 debian-snapshot:
        make VERSION=$(VERSION) clean
-       TMPFILE=$$(mktemp /tmp/notmuch.XXXXXX);         \
-         cp debian/changelog $${TMPFILE};              \
-         EDITOR=/bin/true dch -b -v $(VERSION)+1       \
-           -D UNRELEASED 'test build, not for upload'; \
-         echo '3.0 (native)' > debian/source/format;   \
-         debuild -us -uc;                              \
-         mv -f $${TMPFILE} debian/changelog;           \
-         echo '3.0 (quilt)' > debian/source/format
+       RETVAL=0 &&                                             \
+         TMPFILE=$$(mktemp /tmp/notmuch.XXXXXX) &&             \
+         cp debian/changelog $${TMPFILE} &&                    \
+         (EDITOR=/bin/true dch -b -v $(VERSION)+1              \
+           -D UNRELEASED 'test build, not for upload' &&       \
+         echo '3.0 (native)' > debian/source/format &&         \
+         debuild -us -uc); RETVAL=$$?                          \
+         mv -f $${TMPFILE} debian/changelog;                   \
+         echo '3.0 (quilt)' > debian/source/format;            \
+         exit $$RETVAL
 
 .PHONY: release-message
 release-message:
 
 .PHONY: release-message
 release-message: