RT now integrates with CVS

I’m proud to announce the initial release of the RT cvs commit handler.
This tool allows developers working with a CVS repository to automatically
update tickets in RT as they commit changes to CVS.

You can pick up the latest copy of the code from:
ftp://ftp.fsck.com/pub/rt/contrib/2.0/rt-addons/rt-commit-handler

To install the code, copy it to ~rt/bin, ‘chgrp rt rt-coomit-handler’,
and ‘chmod g+s rt-commit-handler’.

Stick the following in in CVSROOT/commitinfo

ALL /home/jesse/projects/rt-addons/log_accum --record-last-dir

Stick the following in CVSROOT/loginfo

ALL /home/jesse/projects/rt-addons/log_accum -r %{Vvts}

It should work with local cvs servers or cvs servers accessed over rsh/ssh.
I’ve got no idea how it will fare against a pserver. (There may be minor auth
changes).

RT currently needs to live on the same server as CVS.

To use this puppy, your developers all need to have their “Unix login” field
set to the uid that they connect to the CVS server as.

Making it go is simply a matter of embedding commands at the start of the
commit log message. Commands are executed in the order they’re listed.
If you put in repeated calls to RT-Ticket, you can perform actions on
more than one ticket (in serial, not in parallel).
The valid commands are as follows:

RT-Ticket:
RT-Status:
RT-Subject:
RT-Owner:
RT-Priority:
RT-Final-Priority:
RT-Queue:
RT-Requestor: +email@domain
RT-Requestor: -email@domain
RT-Cc: +email@domain
RT-Cc: -email@domain
RT-AdminCc: +email@domain
RT-AdminCc: -email@domain
RT-Due:
RT-Starts:
RT-Started:
RT-Resolved:
RT-: +
RT-: -

The structure of a commit log is:


If the commit log starts with ‘private’ or ‘comment’, it will be
appended to all the tickets you mentioned above as a comment, otherwise,
it will be appended as correspondence. You should note that the commit log
is appended to the ticket before actions are taken.

Feedback is, of course, appreciated.

Thanks,

Jesse

http://www.bestpractical.com/products/rt – Trouble Ticketing. Free.

rt-announce mailing list
rt-announce@lists.fsck.com
http://lists.fsck.com/mailman/listinfo/rt-announce

Hi, Jessy

Was really funny to hack you code a little :wink:
It works fine with pserver access but if one corrects some
bugs/inconsistances
For example instead of

ALL /home/jesse/projects/rt-addons/log_accum --record-last-dir
one should probably use
ALL /home/jesse/projects/rt-addons/rt-coomit-handler --record-last-dir
and so on…
Bugs found:

  • multi line log message appears like one string in RT ticket
  • one should change $CVSROOT variable
  • line 397 -> id = untaint($id); should be $id = untaint($id);

Also I’ve made some improvements to your code. If you are interested I can
post it.

SergeyFrom: “Jesse Vincent” jesse@bestpractical.com
To: rt-announce@fsck.com
Sent: Tuesday, November 13, 2001 10:21 AM
Subject: [rt-users] [rt-announce] RT now integrates with CVS

I’m proud to announce the initial release of the RT cvs commit handler.
This tool allows developers working with a CVS repository to automatically
update tickets in RT as they commit changes to CVS.

You can pick up the latest copy of the code from:
ftp://ftp.fsck.com/pub/rt/contrib/2.0/rt-addons/rt-commit-handler

To install the code, copy it to ~rt/bin, ‘chgrp rt rt-coomit-handler’,
and ‘chmod g+s rt-commit-handler’.

Stick the following in in CVSROOT/commitinfo

ALL /home/jesse/projects/rt-addons/log_accum --record-last-dir

Stick the following in CVSROOT/loginfo

ALL /home/jesse/projects/rt-addons/log_accum -r %{Vvts}

It should work with local cvs servers or cvs servers accessed over
rsh/ssh.
I’ve got no idea how it will fare against a pserver. (There may be minor
auth
changes).

RT currently needs to live on the same server as CVS.

To use this puppy, your developers all need to have their "Unix login"
field
set to the uid that they connect to the CVS server as.

Making it go is simply a matter of embedding commands at the start of the
commit log message. Commands are executed in the order they’re listed.
If you put in repeated calls to RT-Ticket, you can perform actions on
more than one ticket (in serial, not in parallel).
The valid commands are as follows: