--- kgb-bot-1.03.orig/debian/kgb-bot.dirs +++ kgb-bot-1.03/debian/kgb-bot.dirs @@ -0,0 +1 @@ +/var/log --- kgb-bot-1.03.orig/debian/watch +++ kgb-bot-1.03/debian/watch @@ -0,0 +1,3 @@ +version=3 +https://alioth.debian.org/frs/?group_id=100408 \ + .+/kgb-bot_([\d.]+)\.orig\.tar\.gz --- kgb-bot-1.03.orig/debian/kgb-client.install +++ kgb-bot-1.03/debian/kgb-client.install @@ -0,0 +1,12 @@ +usr/bin/kgb-client +usr/share/man/man1/kgb-client* +usr/share/man/man3/App::KGB::Change* +usr/share/man/man3/App::KGB::Client.* +usr/share/man/man3/App::KGB::Client::ServerRef* +usr/share/man/man3/App::KGB::Client::Subversion* +usr/share/man/man3/App::KGB::Commit* +usr/share/perl5/App/KGB/Change.pm +usr/share/perl5/App/KGB/Client.pm +usr/share/perl5/App/KGB/Client/ServerRef.pm +usr/share/perl5/App/KGB/Client/Subversion.pm +usr/share/perl5/App/KGB/Commit.pm --- kgb-bot-1.03.orig/debian/changelog +++ kgb-bot-1.03/debian/changelog @@ -0,0 +1,231 @@ +kgb-bot (1.03-1ubuntu1) maverick; urgency=low + + * debian/control: build dependency on language-pack-bg-base and deleted + build dependency on missing locales-all. This fixes a FTBFS (LP: #572538) + * debian/rules: deleted test on versions as it always fails with ubuntu + versioning + + -- Fabrice Coutadeur Thu, 17 Jun 2010 04:19:41 +0000 + +kgb-bot (1.03-1) unstable; urgency=low + + * New upstream release + + adds rotocol v2 with the ability to explicitly specify revision prefix, + which is 'r' for Subversion and empty otherwise + * Standardss-Version: 3.8.4 (no changes necessary) + + -- Damyan Ivanov Wed, 28 Apr 2010 23:40:15 +0300 + +kgb-bot (1.01-3) unstable; urgency=medium + + * Make 'restart' init.d script action stop and re-start the daemon as + directed by the policy. Closes: #566004. Thanks to Evgeni Golov. + + -- Damyan Ivanov Mon, 25 Jan 2010 18:40:15 +0200 + +kgb-bot (1.01-2) unstable; urgency=low + + [ gregor herrmann ] + * Build depend on locales-all and run tests under a UTF-8 locale + (closes: #560657). + + [ Damyan Ivanov ] + * add a watch file + + -- Damyan Ivanov Fri, 11 Dec 2009 22:27:36 +0200 + +kgb-bot (1.01-1) unstable; urgency=low + + * New upstream release + + Fixex client when cross-branch/module commits are made + + -- Damyan Ivanov Sat, 05 Dec 2009 16:16:02 +0200 + +kgb-bot (1.00-1) unstable; urgency=low + + * New upsream release + + Fixes support for unicode commit messages + + -- Damyan Ivanov Wed, 02 Dec 2009 19:34:35 +0200 + +kgb-bot (0.16-1) unstable; urgency=low + + * New upstream release + + -- Damyan Ivanov Tue, 24 Nov 2009 18:49:49 +0200 + +kgb-bot (0.15-1) unstable; urgency=low + + * New upstream release + * Split Git support in kgb-client-git + - avoids a bunch of dependencies being installed with the server + * kgb-bot: drop polygen and libipc-run-perl to Recommends + + -- Damyan Ivanov Sat, 07 Nov 2009 16:22:01 +0200 + +kgb-bot (0.14-1) unstable; urgency=low + + * New upstream release + + make kgb-bot depend on kgb-client (it uses some of its modules) + + -- Damyan Ivanov Mon, 02 Nov 2009 22:34:17 +0200 + +kgb-bot (0.13-1) unstable; urgency=low + + * New upstream release + + -- Damyan Ivanov Sun, 01 Nov 2009 18:22:25 +0200 + +kgb-bot (0.12-1) unstable; urgency=low + + * New upstream release + * rules: check that package version matches module version + + -- Damyan Ivanov Sat, 31 Oct 2009 16:04:55 +0200 + +kgb-bot (0.11-1) unstable; urgency=low + + * new upstream release + + the autoresponder can use polygen + * add polygen and libipc-run-perl to Recommends + + -- Damyan Ivanov Mon, 26 Oct 2009 21:03:15 +0200 + +kgb-bot (0.10-1) unstable; urgency=low + + * New upstream release + + kgb-bot no longer needs App::KGB, which is in the kgb-client package + + -- Damyan Ivanov Sun, 25 Oct 2009 21:09:00 +0200 + +kgb-bot (0.09-1) unstable; urgency=low + + * New upstream release + + postinst: set up /var/log/kgb-bot.log if not present + + respond to !version command (only allowed to a list of masks) + + also handle private messages + + -- Damyan Ivanov Sat, 24 Oct 2009 19:14:17 +0300 + +kgb-bot (0.08-1) unstable; urgency=low + + * new upstream release + + fixes a typo causing crash on received IRC messages + + -- Damyan Ivanov Wed, 21 Oct 2009 08:17:46 +0300 + +kgb-bot (0.07-1) unstable; urgency=low + + [ Damyan Ivanov ] + * add Git support + * set Maintainer address to kgb-maintainers@lists.alioth.d.o + * add --git-reflog switch, passed to Client::Git + * add support for a dummy "_ECHO_" network + * add an example bot config useful for local testing + * mention supported VCS in kgb-client long description + * drop included RateLimit and use send_queue to detect congestion + * use non-svn-checkout upstream source location + * add git-core as (build-) dependency + * Update Vcs-* URLs to match the new home on Alioth + * Section: net->devel; Priority: extra->optional + + * Upload to Debian + + -- Damyan Ivanov Wed, 21 Oct 2009 01:17:15 +0300 + +kgb-bot (0.06) unstable; urgency=low + + * client: install App::KGB::Client* in kgb-client + * install also the manuals + * use Module::Build + + -- Damyan Ivanov Thu, 01 Oct 2009 22:31:11 +0300 + +kgb-bot (0.05) unstable; urgency=low + + [ Martín Ferrari ] + * server + + Decode utf8 sequences before passing to sha1_hex function. Fixes DoS with + extended chars in the commit log. + * client + + Try to correctly handle the svn-provided strings, convertien them to utf8 + sequences. Decode them before sha1 and use the utf8 versions for SOAP. + This triggers a bug in SOAP::Lite 0.710.08, because it incorrectly + handles utf8 strings. + + -- Damyan Ivanov Sat, 26 Sep 2009 11:00:33 +0300 + +kgb-bot (0.04) unstable; urgency=low + + [ Damyan Ivanov ] + * server + + use "dir" or "dirs" depending on the number (1 or greater) + + make colors configurable + + drop ":" after repository name + * client + + avoid wrong trimming of changed paths when branch or module cannot be + detected + + fix population of default password and proxy for servers + + move checksum calculation back into servers loop + + randomize server list + + improve documentation + + split self-contained parts of the code into separate modules as + preparation for Git support + + add --verbose option + * split client script/man in kgb-client package + * add syntax check and POD tests + + [ gregor herrmann ] + * debian/rules: simplify, and don't compress examples. + + -- Damyan Ivanov Mon, 14 Sep 2009 16:32:01 +0300 + +kgb-bot (0.03) unstable; urgency=low + + [ Damyan Ivanov ] + * make dependency on libpoe-component-irc-perl versioned >= 5.56, in which + NickServID plugin is first mentioned + * add support for a list of answers + * make all IO handles use utf8 encoding + + [ Martín Ferrari ] + * server/KGB: move configuration reading and verification to a subroutine, + for future support of config reloading. + * server/KGB: separate into packages for clearer code. Allow SIGQUIT to + restart the server (with complete close and disconnect). + * server/KGB: support for reloading the configuration file with SIGHUP. + * server/KGB: fixed an error in the password verification (protocol 1). + Protocol versions: use a hardcoded hash of the *really* supported + versions, and then a configuration option to filter them out. + * debian/*, server/KGB, Makefile: match the /etc directory name with the + package name. + * client/*: remove hardcodings. + * debian/init: make use of the SIG(HUP|QUIT) handlers. + * client/KGB_sendcommit: use v1 protocol. + * server/KGB: daemonize, handle parent/child communication during setup, and + forcefully die when POE gets silly. + * server/KGB, server/kgb.conf.sample: now the bot answers when addressed on a + channel. + * server/KGB, server/kgb.conf.sample: support for rate limiting the SOAP + interface (only global limits, not per client). + * client/KGB_sendcommit: shut up the compiler warnings about typos. + + [ gregor herrmann ] + * debian/control: + - fix Vcs-Svn URL + - bump Standards-Version to 3.8.1 + - add ${misc:Depends}, ${perl:Depends} to Depends + + [ Damyan Ivanov ] + * implement server failover + * create /var/run/kgb-bot in the init script + * client: process faults synchronously, report verbosely + * add support for discovering branch and package name + * server: fix branch/module colourization + * bump perl (build) dependency to 5.10 + * remove the slash after the module name + * strip leading shash from transmitted paths + * omit flags if the change is a mere modification + * bump Standards-Version to 3.8.3 (no changes needed) + + -- Damyan Ivanov Sun, 06 Sep 2009 15:31:02 +0300 --- kgb-bot-1.03.orig/debian/kgb-bot.default +++ kgb-bot-1.03/debian/kgb-bot.default @@ -0,0 +1,3 @@ +# Configuration for kgb-bot init script +# Set to 1 to enable KGB at startup +BOT_ENABLED=0 --- kgb-bot-1.03.orig/debian/kgb-bot.init +++ kgb-bot-1.03/debian/kgb-bot.init @@ -0,0 +1,170 @@ +#! /bin/sh +### BEGIN INIT INFO +# Provides: kgb-bot +# Required-Start: $remote_fs +# Required-Stop: $remote_fs +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: Collaborative IRC helper +# Description: KGB is an IRC bot, helping people work together by +# notifying an IRC channel when a commit occures. +### END INIT INFO + +# Author: Damyan Ivanov + +# Do NOT "set -e" + +# PATH should only include /usr/* if it runs after the mountnfs.sh script +PATH=/sbin:/usr/sbin:/bin:/usr/bin +DESC="Collaborative IRC helper" +NAME=kgb-bot +DAEMON=/usr/sbin/$NAME +DAEMON_ARGS="--config /etc/kgb-bot/kgb.conf" +PIDFILE=/var/run/kgb-bot/$NAME.pid +SCRIPTNAME=/etc/init.d/$NAME + +# Exit if the package is not installed +[ -x "$DAEMON" ] || exit 0 + +RUN_AS='Debian-kgb' +# Read configuration variable file if it is present +[ -r /etc/default/$NAME ] && . /etc/default/$NAME + +# Load the VERBOSE setting and other rcS variables +. /lib/init/vars.sh + +# Define LSB log_* functions. +# Depend on lsb-base (>= 3.0-6) to ensure that this file is present. +. /lib/lsb/init-functions + +# +# create /var/run/kgb-bot and ensure right permissions +# +init_run_dir() +{ + RUN_DIR="/var/run/$NAME" + [ -d "$RUN_DIR" ] || mkdir "$RUN_DIR" || return 1 + + chown "$RUN_AS":root "$RUN_DIR" + chmod 0775 "$RUN_DIR" + + return 0 +} + +# +# Function that starts the daemon/service +# +do_start() +{ + # Return + # 0 if daemon has been started + # 1 if daemon was already running + # 2 if daemon could not be started + init_run_dir || return 2 + start-stop-daemon --start --quiet --chuid $RUN_AS --pidfile $PIDFILE --exec $DAEMON --test > /dev/null \ + || return 1 + start-stop-daemon --start --quiet --chuid $RUN_AS --pidfile $PIDFILE --exec $DAEMON -- \ + $DAEMON_ARGS \ + || return 2 + # Add code here, if necessary, that waits for the process to be ready + # to handle requests from services started subsequently which depend + # on this one. As a last resort, sleep for some time. +} + +# +# Function that stops the daemon/service +# +do_stop() +{ + # Return + # 0 if daemon has been stopped + # 1 if daemon was already stopped + # 2 if daemon could not be stopped + # other if a failure occurred + start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --name $NAME + RETVAL="$?" + [ "$RETVAL" = 2 ] && return 2 + # Wait for children to finish too if this is a daemon that forks + # and if the daemon is only ever run from this initscript. + # If the above conditions are not satisfied then add some other code + # that waits for the process to drop all resources that could be + # needed by services started subsequently. A last resort is to + # sleep for some time. + start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 --exec $DAEMON + [ "$?" = 2 ] && return 2 + # Many daemons don't delete their pidfiles when they exit. + rm -f $PIDFILE + return "$RETVAL" +} + +# +# Function that sends a SIGHUP to the daemon/service +# +do_reload() { + start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE --name $NAME + return 0 +} + +# +# Function that sends a SIGQUIT to the daemon/service +# +do_soft_restart() { + start-stop-daemon --stop --signal 3 --quiet --pidfile $PIDFILE --name $NAME + return 0 +} + +case "$1" in + start) + [ "$BOT_ENABLED" != "1" ] && echo $DAEMON disabled in /etc/default/$NAME>&2 && exit 0 + + [ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME" + do_start + case "$?" in + 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; + 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; + esac + ;; + stop) + [ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME" + do_stop + case "$?" in + 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; + 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; + esac + ;; + soft-restart) + log_daemon_msg "Reloading $DESC" "$NAME" + do_soft_restart + log_end_msg $? + ;; + reload|force-reload) + log_daemon_msg "Reloading $DESC" "$NAME" + do_reload + log_end_msg $? + ;; + restart) + log_daemon_msg "Restarting $DESC" "$NAME" + do_stop + case "$?" in + 0|1) + do_start + case "$?" in + 0) log_end_msg 0 ;; + 1) log_end_msg 1 ;; # Old process is still running + *) log_end_msg 1 ;; # Failed to start + esac + ;; + *) + # Failed to stop + log_end_msg 1 + ;; + esac + ;; + *) + echo "Usage: $SCRIPTNAME {start|stop|restart|force-restart|reload|force-reload}" >&2 + #echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2 + exit 3 + ;; +esac + +: --- kgb-bot-1.03.orig/debian/copyright +++ kgb-bot-1.03/debian/copyright @@ -0,0 +1,27 @@ +Upstream source is available frop http://alioth.debian.org/projects/kgb + +Upstream authors: + Martín Ferrari + Damyan Ivanov + +Copyright: +# Copyright © 2008 Martín Ferrari +# Copyright © 2008,2009,2010 Damyan Ivanov + +License: +# 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., 51 +# Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +On Debian systems, the complete text of GNU General Public License is available +in /usr/share/common-licenses/GPL --- kgb-bot-1.03.orig/debian/compat +++ kgb-bot-1.03/debian/compat @@ -0,0 +1 @@ +7 --- kgb-bot-1.03.orig/debian/kgb-client.examples +++ kgb-bot-1.03/debian/kgb-client.examples @@ -0,0 +1,2 @@ +eg/kgb-client.conf.sample +eg/post-commit --- kgb-bot-1.03.orig/debian/kgb-bot.install +++ kgb-bot-1.03/debian/kgb-bot.install @@ -0,0 +1,3 @@ +usr/sbin/* +usr/share/man/man1/kgb-bot* +etc/kgb-bot/* --- kgb-bot-1.03.orig/debian/kgb-bot.postinst +++ kgb-bot-1.03/debian/kgb-bot.postinst @@ -0,0 +1,23 @@ +#!/bin/sh + +set -e +set -u + +if [ "$1" = "configure" ]; then + adduser --system --quiet --group --home /dev/null --no-create-home \ + --disabled-login --gecos "KGB bot" --force-badname Debian-kgb + + if ! dpkg-statoverride --list /etc/kgb-bot/kgb.conf > /dev/null; then + dpkg-statoverride --update --add root Debian-kgb 0640 /etc/kgb-bot/kgb.conf + fi +fi + +LOG=/var/log/kgb-bot.log + +if ! test -e $LOG; then + touch $LOG + chown Debian-kgb:root $LOG + chmod 0644 $LOG +fi + +#DEBHELPER# --- kgb-bot-1.03.orig/debian/rules +++ kgb-bot-1.03/debian/rules @@ -0,0 +1,12 @@ +#!/usr/bin/make -f + +%: + dh --buildsystem=perl_build $@ + +override_dh_compress: + dh_compress -Xexamples + +PKG_VER := $(shell dpkg-parsechangelog | egrep '^Version:' | sed 's/^Version: \(.\+\)-[0-9]\+$$/\1/') +MOD_VER := $(shell perl -Ilib -MApp::KGB -e'print $$App::KGB::VERSION') +override_dh_auto_test: + LANG=bg_BG.utf8 LC_ALL=bg_BG.utf8 dh_auto_test --- kgb-bot-1.03.orig/debian/kgb-client-git.install +++ kgb-bot-1.03/debian/kgb-client-git.install @@ -0,0 +1,2 @@ +usr/share/perl5/App/KGB/Client/Git.pm +usr/share/man/man3/App::KGB::Client::Git* --- kgb-bot-1.03.orig/debian/control +++ kgb-bot-1.03/debian/control @@ -0,0 +1,89 @@ +Source: kgb-bot +Section: devel +Priority: optional +Build-Depends: debhelper (>= 7.0.50) +Build-Depends-Indep: perl (>= 5.10), + perl (>= 5.10.1) | libautodie-perl, + libclass-accessor-perl, + libdigest-sha1-perl, + libipc-run-perl, + libipc-system-simple-perl, + libpoe-component-irc-perl (>= 5.56), + libpoe-component-server-soap-perl, + libpoe-perl, + libproc-pid-file-perl, + libsoap-lite-perl, + libsvn-perl, + libtest-compile-perl, + libtest-pod-coverage-perl, + libtest-pod-perl, + perl (>= 5.10.1) | libtest-simple-perl (>= 0.92), + libyaml-perl, + git-core, + subversion, + language-pack-bg-base +Vcs-Svn: svn://svn.debian.org/kgb/kgb/ +Vcs-Browser: http://svn.debian.org/viewsvn/kgb/kgb/ +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Debian KGB Maintainers +Uploaders: Martín Ferrari , Damyan Ivanov +Standards-Version: 3.8.4 + +Package: kgb-bot +Architecture: all +Depends: ${misc:Depends}, ${perl:Depends}, adduser, perl (>= 5.10), + libdigest-sha1-perl, + libpoe-component-irc-perl (>= 5.56), + libpoe-component-server-soap-perl, + libpoe-perl, + libproc-pid-file-perl, + libyaml-perl, + kgb-client +Suggests: polygen, libipc-run-perl +Description: IRC collaboration bot + KGB is an IRC bot, helping people work together by notifying an IRC channel + when a commit occures. + . + It supports multiple repositories/IRC channels and is fully configurable. + . + This package contains the server-side daemon, kgb-bot, which is responsible + for relaying commit notifications to IRC. + +Package: kgb-client +Architecture: all +Depends: ${misc:Depends}, ${perl:Depends}, perl (>= 5.10), + libclass-accessor-perl, + libdigest-sha1-perl, + libsoap-lite-perl, + libsvn-perl, + libyaml-perl +Recommends: kgb-client-git +Suggests: kgb-bot +Description: client for KGB (IRC collaboration bot) + KGB is an IRC bot, helping people work together by notifying an IRC channel + when a commit occures. + . + It supports multiple repositories/IRC channels and is fully configurable. + . + This package contains the client-side program, kgb-client, which is supposed + to be used as an hook in your version control system and sends the + notifications to the KGB daemon. + . + Currently supported version control systems are: + * Subversion + * Git + . + Note that Git support is provided by a separate package, kgb-client-git + +Package: kgb-client-git +Architecture: all +Depends: ${misc:Depends}, ${perl:Depends}, + git-core, + kgb-client, + libipc-run-perl +Enhances: kgb-client +Description: client for KGB (IRC collaboration bot) - Git support + KGB is an IRC bot, helping people work together by notifying an IRC channel + when a commit occures. + . + This package adds support to Git version control system to kgb-client.