Subject: | Multiple RT reports when using svk smerge -l |
This is not so much a bug as a feature request or consideration.
The current PullUpdate.html looks for ^\s*RT- to trigger changes in the RT database.
When doing smart merges with svk sm -sl, old logs, which have already triggered something in
the RT database do the same trigger again.
One way around this would be to match on ^RT- as the smart merge indents the commit
messages it gathers.
We can implement this for ourselves, but thought it might be useful elsewhere, so the simple
patch is attached.
Subject: | svk.smerge-l.diff |
--- PullUpdate.html.orig 2006-10-04 17:39:46.000000000 -0700
+++ PullUpdate.html 2006-10-04 17:40:48.000000000 -0700
@@ -51,21 +51,21 @@
my $update_owner = '';
my %set;
foreach my $line (@msg) {
- if ( $line =~ /^\s*RT-Ticket:\s*(\w*?)(?:\#?)(\d*)/i ) {
+ if ( $line =~ /^RT-Ticket:\s*(\w*?)(?:\#?)(\d*)/i ) {
next if ($1 && $1 !~ /^$RT::rtname$/i);
$ticket = RT::Ticket->new($user);
$ticket->Load($2);
}
- elsif ( $line =~ /^\s*RT-Status:\s*(\w+)/i ) {
+ elsif ( $line =~ /^RT-Status:\s*(\w+)/i ) {
$update_status = lc($1);
}
- elsif ( $line =~ /^\s*RT-(?:Update|Action):\s*(comment|correspond)/i ) {
+ elsif ( $line =~ /^RT-(?:Update|Action):\s*(comment|correspond)/i ) {
$update_type = lc($1);
}
- elsif ( $line =~ /^\s*RT-Owner:\s*(\w+)/i ) {
+ elsif ( $line =~ /^RT-Owner:\s*(\w+)/i ) {
$update_owner = $1;
}
- elsif ( $line =~ /^\s*RT-(\w+):\s*(\w+)/i ) {
+ elsif ( $line =~ /^RT-(\w+):\s*(\w+)/i ) {
$set{$1} = $2;
}
else {