]> git.pld-linux.org Git - packages/rpm-build-tools.git/commitdiff
- handle errors from pldnotify.awk
authorElan Ruusamäe <glen@pld-linux.org>
Mon, 30 Aug 2010 15:03:39 +0000 (15:03 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    builder.sh -> 1.630

builder.sh

index b2934ecb076f6fcb4912fa645136044496531d4e..8dcae8f154dd5c24404b586337b5ef2ff4c09d49 100644 (file)
@@ -1457,6 +1457,13 @@ try_upgrade() {
                                TNOTIFY=$($APPDIR/pldnotify.awk ${BE_VERBOSE:+-vDEBUG=1} $SPECFILE) || exit 1
                        fi
 
+                       # pldnotify.awk does not set exit codes, but it has match for ERROR
+                       # in output which means so.
+                       if [[ "$TNOTIFY" = *ERROR* ]]; then
+                               echo >&2 "$TNOTIFY"
+                               exit 1
+                       fi
+
                        TNEWVER=$(echo $TNOTIFY | awk '{ match($4,/\[NEW\]/); print $5 }')
                fi
 
This page took 0.039452 seconds and 4 git commands to generate.