[26310] in Source-Commits

home help back first fref pref prev next nref lref last post

/svn/athena r25512 - trunk/debathena/scripts

daemon@ATHENA.MIT.EDU (Jonathan D Reed)
Wed May 16 11:52:44 2012

Date: Wed, 16 May 2012 11:52:42 -0400
From: Jonathan D Reed <jdreed@MIT.EDU>
Message-Id: <201205161552.q4GFqgZu021221@drugstore.mit.edu>
To: source-commits@MIT.EDU
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Author: jdreed
Date: 2012-05-16 11:52:42 -0400 (Wed, 16 May 2012)
New Revision: 25512

Modified:
   trunk/debathena/scripts/dasource
Log:
- Don't die if grep-dctrl returns non-zero
- Throw in an EXIT trap for future generations to provide some feedback
  if we die


Modified: trunk/debathena/scripts/dasource
===================================================================
--- trunk/debathena/scripts/dasource	2012-05-16 15:41:50 UTC (rev 25511)
+++ trunk/debathena/scripts/dasource	2012-05-16 15:52:42 UTC (rev 25512)
@@ -15,6 +15,8 @@
 
 set -e
 
+trap 'echo "dasource failed: Source package _not_ created"' EXIT
+
 die() {
   echo "$@" >&2
   exit 1
@@ -100,8 +102,8 @@
   # Read in debian-versions
   . $basedir/debian-versions.sh
 
-  NOBUILD=$(grep-dctrl -n -s X-Debathena-No-Build -F X-Debathena-No-Build -e . "$dir/debian/control")
-  BUILDFOR=$(grep-dctrl -n -s X-Debathena-Build-For -F X-Debathena-Build-For -e . "$dir/debian/control")
+  NOBUILD=$(grep-dctrl -n -s X-Debathena-No-Build -F X-Debathena-No-Build -e . "$dir/debian/control" || true)
+  BUILDFOR=$(grep-dctrl -n -s X-Debathena-Build-For -F X-Debathena-Build-For -e . "$dir/debian/control" || true)
   if [ -n "$NOBUILD" ] && [ -n "$BUILDFOR" ]; then
       echo "It is an error to specify both X-Debathena-Build-For and"
       echo "X-Debathena-No-Build.  Pick one and try again."


home help back first fref pref prev next nref lref last post