From 5731730ed64bc54a575f195cbdc911e56480dc8c Mon Sep 17 00:00:00 2001 From: Chris Larson Date: Thu, 27 May 2004 19:13:36 +0000 Subject: Attempt to fix CIA trigger on recent bk versions. BKrev: 40b63de0GFFIGjG-Yf0cB6jF69Gkiw --- BitKeeper/triggers/post-outgoing.ciabot | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) (limited to 'BitKeeper/triggers') diff --git a/BitKeeper/triggers/post-outgoing.ciabot b/BitKeeper/triggers/post-outgoing.ciabot index 8a7132789f..3fead58232 100644 --- a/BitKeeper/triggers/post-outgoing.ciabot +++ b/BitKeeper/triggers/post-outgoing.ciabot @@ -42,16 +42,22 @@ check_sanity () { # Check sanity - do we need to send anything? check_sanity || exit 0 -# Convert numbers from the cset list into something useful -nums= -for s in `cat $BK_CSETLIST`; do - # translate cset serial to cset # - n=`bk prs -h -d"\\$if(:DS: -eq $s){:REV:}" ChangeSet` - # dont send notifications about empty ChangeSets - if test -z `bk prs -h -r"$n" -d'$if(:LI: -eq 0){$if(:LD: -eq 0){:REV:}}' ChangeSet`; then - nums="$n $nums" - fi -done +if (grep -q ':ChangeSet:' $BK_CSETLIST); then + # new, correct csets-out format + nums = `bk changes -d:REV: - < $BK_CSETLIST` +else + + # Convert numbers from the cset list into something useful + nums= + for s in `cat $BK_CSETLIST`; do + # translate cset serial to cset # + n=`bk prs -h -d"\\$if(:DS: -eq $s){:REV:}" ChangeSet` + # dont send notifications about empty ChangeSets + if test -z `bk prs -h -r"$n" -d'$if(:LI: -eq 0){$if(:LD: -eq 0){:REV:}}' ChangeSet`; then + nums="$n $nums" + fi + done +fi # Send notifications to CIA if test -n "$nums"; then -- cgit v1.2.3