From 857f7f2f6466a0db36a663cd542779bbacd892ed Mon Sep 17 00:00:00 2001 From: "nslu2-linux.adm@bkbits.net" Date: Thu, 6 Jan 2005 20:40:07 +0000 Subject: Merge bk://oe-devel.bkbits.net/openembedded into bkbits.net:/repos/n/nslu2-linux/openembedded 2005/01/06 15:38:50-05:00 handhelds.org!kergoth Trigger cleanup. 2005/01/06 15:34:46-05:00 handhelds.org!kergoth test trigger. 2005/01/06 15:27:00-05:00 handhelds.org!kergoth Another trigger test. 2005/01/06 15:25:37-05:00 handhelds.org!kergoth Correct the permissions on the cia post outgoing trigger. 2005/01/06 15:22:37-05:00 handhelds.org!kergoth Bugfix in the outgoing trigger 2005/01/06 15:20:56-05:00 handhelds.org!kergoth Bugfix in the outgoing trigger 2005/01/06 15:19:21-05:00 handhelds.org!kergoth Bugfix in the outgoing trigger 2005/01/06 15:16:01-05:00 handhelds.org!kergoth Trigger updates. 2005/01/06 14:33:52-05:00 handhelds.org!kergoth Test cset for bk triggers. BKrev: 41dda227eA_vQY_qU1rMB9abvxBNSw --- BitKeeper/etc/ciabot.projects | 0 BitKeeper/triggers/ciabot.config | 19 ------- BitKeeper/triggers/ciabot.projects | 3 - BitKeeper/triggers/ciabot_bk.py | 0 BitKeeper/triggers/ciabot_bk.sh | 66 ---------------------- BitKeeper/triggers/post-outgoing | 64 ---------------------- BitKeeper/triggers/post-outgoing.cia | 0 BitKeeper/triggers/post-outgoing.ciabot | 97 --------------------------------- 8 files changed, 249 deletions(-) create mode 100644 BitKeeper/etc/ciabot.projects delete mode 100644 BitKeeper/triggers/ciabot.config delete mode 100644 BitKeeper/triggers/ciabot.projects create mode 100644 BitKeeper/triggers/ciabot_bk.py delete mode 100644 BitKeeper/triggers/ciabot_bk.sh delete mode 100644 BitKeeper/triggers/post-outgoing create mode 100644 BitKeeper/triggers/post-outgoing.cia delete mode 100644 BitKeeper/triggers/post-outgoing.ciabot (limited to 'BitKeeper') diff --git a/BitKeeper/etc/ciabot.projects b/BitKeeper/etc/ciabot.projects new file mode 100644 index 0000000000..e69de29bb2 diff --git a/BitKeeper/triggers/ciabot.config b/BitKeeper/triggers/ciabot.config deleted file mode 100644 index 42d4e0c68d..0000000000 --- a/BitKeeper/triggers/ciabot.config +++ /dev/null @@ -1,19 +0,0 @@ -# -# ciabot.config -- Configuration file for ciabot -# -# Note: The IRC network name is ignored for now, but must be included. -# What you say here end up as a prefix on each row of your logs -# on #commits. You must use the name of your projects IRC channel in -# order to invite the bot there. -# -# example: -# IRCCHANNEL=irc.freenode.net/ourprojectchannel -IRCCHANNEL=irc.freenode.net/#openembedded - -# The email address where we send the commit messages. -COMMITADDRESS=commits@picogui.org - -# Verbose flag, if not empty, show individual file history -# VERBOSE=yes - -# End diff --git a/BitKeeper/triggers/ciabot.projects b/BitKeeper/triggers/ciabot.projects deleted file mode 100644 index d7aab30d3e..0000000000 --- a/BitKeeper/triggers/ciabot.projects +++ /dev/null @@ -1,3 +0,0 @@ -openembedded openembedded.bkbits.net oe@handhelds.org -openembedded oe-devel.bkbits.net oe@handhelds.org -nslu2-linux nslu2-linux.bkbits.net nslu2-linux@yahoogroups.com diff --git a/BitKeeper/triggers/ciabot_bk.py b/BitKeeper/triggers/ciabot_bk.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/BitKeeper/triggers/ciabot_bk.sh b/BitKeeper/triggers/ciabot_bk.sh deleted file mode 100644 index b12890574b..0000000000 --- a/BitKeeper/triggers/ciabot_bk.sh +++ /dev/null @@ -1,66 +0,0 @@ -#!/bin/sh -# -# CIA bot client script for BitKeeper repositories, delivering via email -# -- Chris Larson -# -# Based on ciabot_svn.sh by Micah Dowty -# -# See http://cia.navi.cx -# for more information on what the CIA bot is and how it works. -# -############# There are some parameters for this script that you can customize: - -# Project information -[ -z "$project_name" ] && project_name="openembedded" -[ -z "$return_address" ] && return_address="oe@handhelds.org" - -# System -sendmail_command="/usr/sbin/sendmail -t" - -############# Below this line you shouldn't have to change anything - -# Script arguments -REV="$1" - -# The email address CIA lives at -cia_address="cia@navi.cx" - -author=`bk changes -r"$REV" -d":P:" | sed 's/\&/\&/g;s//\>/g'` -module=`basename $BKD_ROOT | sed 's/\&/\&/g;s//\>/g'` -tag=`bk changes -r"$REV" -d":TAG:" | sed 's/\&/\&/g;s//\>/g'` -for file in `bk changes -n -v -r"$REV" -d"\\\$unless(:GFILE:=ChangeSet){:GFILE:}" | sort -u | sed 's/\&/\&/g;s//\>/g'`; do - files="$files$file" -done - -# Send an email with the final XML message -(cat < - - BitKeeper CIA Bot client shell script - 1.1 - - - $project_name - $module - $tag - - - - $REV - $author - $files -EOF -echo " " -bk changes -r"$REV" -d'$if(:C:){$each(:C:){:C: \\n}}' | sed -e 's/\&/\&\;/g;s//\>\;/g;' -echo " " -cat < - - -EOF -) | $sendmail_command diff --git a/BitKeeper/triggers/post-outgoing b/BitKeeper/triggers/post-outgoing deleted file mode 100644 index b9c00d6b86..0000000000 --- a/BitKeeper/triggers/post-outgoing +++ /dev/null @@ -1,64 +0,0 @@ -#!/bin/sh - -LIST=openzaurus-cvslogs@lists.sf.net - -exit 0 - -if [ X"$BK_STATUS" = XDRYRUN -o X"$BK_STATUS" = XNOTHING ] -then exit 0 -fi - -if [ "$BK_SIDE" = server ] -then U=$BKD_USER - H=$BKD_HOST - R=$BKD_ROOT -else U=$BK_USER - H=$BK_HOST - R=$BK_ROOT -fi -R_OUT=`echo $BKD_ROOT | sed "s,.*/,,"` - -if !(echo $BKD_HOST|grep -q bitkeeper.com) -then exit 0 -fi - -if [ $BK_SIDE != client ] -then exit 0 -fi - -echo "Sending notification mail to $LIST..." - -( - echo ${U}@${H} fired the $BK_TRIGGER trigger in $R_OUT - case "$BK_TRIGGER" in - pre-outgoing) VERB=Sending;; - post-outgoing) VERB=Sent;; - pre-incoming) VERB=Receiving;; - post-incoming) VERB=Received;; - pre-resolve) VERB=Resolving;; - pre-commit) VERB=Committing;; - post-commit) VERB=Committed;; - pre-apply) VERB=Applying;; - esac - if [ X"$BK_PENDING" != X ] - then ( - echo $VERB the following deltas - echo - bk prs - < $BK_PENDING - ) | sed 's/^/ /' - fi - if [ X"$BK_CSETLIST" != X ] - then ( - echo $VERB the following changesets - echo - bk changes -v - < $BK_CSETLIST - ) | sed 's/^/ /' - fi - if [ X"$BK_CSETS" != X ] - then ( - echo $VERB the following changesets - echo - bk changes -v -r$BK_CSETS - ) | sed 's/^/ /' - fi -) | mail -s "${U}@${H}:${R} - $BK_EVENT" $LIST diff --git a/BitKeeper/triggers/post-outgoing.cia b/BitKeeper/triggers/post-outgoing.cia new file mode 100644 index 0000000000..e69de29bb2 diff --git a/BitKeeper/triggers/post-outgoing.ciabot b/BitKeeper/triggers/post-outgoing.ciabot deleted file mode 100644 index 5937cc6d4b..0000000000 --- a/BitKeeper/triggers/post-outgoing.ciabot +++ /dev/null @@ -1,97 +0,0 @@ -#!/bin/sh -# -# ex:ts=4:sw=4:sts=4:et -# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- -# -# Copyright (C) 2004 Chris Larson -# -# Sanity checks taken from the scripts on commits.bkbits.net -# Copyright (C) 2003 Leonard Norrgard -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place - Suite 330, -# Boston, MA 02111-1307, USA. - -check_sanity () { - if [ X$BK_SILENT != X ]; then - return 1 - fi - - if [ X$BK_STATUS = XDRYRUN -o X$BK_STATUS = XNOTHING ]; then - return 1 - fi - - # In order to make sure only pushes to public BitKeeper repositories - # are broadcasted to #commits, we check that a) the parent repository - # is on bkbits.net and b) we are the client. - - # Is parent a public BitKeeper repository at bkbits.net? - if !(echo $BKD_HOST|grep -qE '(bitkeeper.com|bitmover.com|bkbits.net)$'); then - return 1 - fi - - if [ $BK_SIDE != client ]; then - return 1 - fi -} - -check_projects () { - if [ ! -e $BK_ROOT/BitKeeper/triggers/ciabot.projects ]; then - return 1 - fi - - while read _p _s _e; do - _sshort=`echo $_s|sed -e's,.bkbits.net,,'` - if (echo $BKD_ROOT|grep -q "/${_sshort}"); then - project_name=${_p} - return_address=${_e} - fi - done < $BK_ROOT/BitKeeper/triggers/ciabot.projects - export project_name return_address - return 0 -} - -# Check sanity - do we need to send anything? -check_sanity || exit 0 - -# Check projects - attempt to determine which bkbits project we are -check_projects || exit 0 - -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 - echo "Sending notification to CIA irc bot (cia.navi.cx)." - ( - for n in $nums; do - $BK_ROOT/BitKeeper/triggers/ciabot_bk.sh $n - done - ) & -fi -exit 0 -- cgit v1.2.3