[PLD] SPECS: frontline.spec - release 5 to rebuild with new libart...

Paweł Żurowski pzurowski w post.pl
Nie, 25 Sty 2004, 23:52:51 CET


W liście z nie, 25-01-2004, godz. 23:06, Paweł Gołaszewski pisze: 
> ok, fajne (podoba mi się takie powiadamianie), ale jest jedno ale...
> wątki. Teraz nie ma wątkowania :(

zmiany tak jak wczesniej + watki[1] + Twoj ostatni commit

[1] - na podstawie starego sposobu logowania

pozdrawiam
-pawel

-- 
Pawel Zurowski
JID: <my_login>@jabber.org
-------------- następna część ---------
Index: cvslog.pl
===================================================================
RCS file: /cvsroot/CVSROOT/cvslog.pl,v
retrieving revision 1.15
diff -u -r1.15 cvslog.pl
--- cvslog.pl	25 Jan 2004 17:19:37 -0000	1.15
+++ cvslog.pl	25 Jan 2004 22:47:26 -0000
@@ -26,12 +26,13 @@
 # TODO: attach diffs (under some length, possibly a diffstat instead),
 #	non-agressively reformat log messages
 #
-# $Id: cvslog.pl,v 1.15 2004/01/25 17:19:37 qboosh Exp $
+# $Id: cvslog.pl,v 1.12 2004/01/25 16:52:40 qboosh Exp $
 
 use strict;
 use vars qw ($project $repository $from_email $dest_email $reply_email
 		$CVS $diffstat $cvsweb_url $help_msg $sync_delay $max_diff_lines
-		$show_diffstat $show_diff $login $subj_files);
+		$show_diffstat $show_diff $login $subj_files $subj_maxlength
+		$withthreading_email $messageid_email);
 
 
 
@@ -61,6 +62,12 @@
 # Email address all the replies should go at.
 $reply_email = 'pld-devel-en w pld-linux.org';
 
+# suffix of Message-ID in email header
+$messageid_email = '@pld-llinux.org';
+
+# with threading?
+$withthreading_email = 1;
+
 # The cvs binary location + name (full path to the executable). If in doubt,
 # try just 'cvs' and hope. Otherwise, /usr/bin/cvs or /usr/local/bin/cvs could
 # do.
@@ -101,6 +108,8 @@
 # Whether you want the affected files list in subject
 $subj_files=1;
 
+# How long the subject can be
+$subj_maxlength=78;
 
 ### The code itself
 
@@ -267,41 +276,64 @@
 $date = scalar gmtime;
 
 
-# Fill in subj and possibly cut it
 
-my ($subj);
-$subj = "Subject: [$project] $module".($tag?" ($tag)":"").($subj_files?": ===FILES=== ":": ").$logmsg;
-$subj =~ s/\n/ /g; $subj =~ s/ *$//;
 
 # Compose the mail
 
 # TODO: Use CVSROOT/users to determine the committer's realname and email and
 # add it to the reply-to / mail-followup-to list. --pasky
 
-my ($VERSION) = '$Revision: 1.15 $' =~ / (\d+\.\d+) /;
+my ($VERSION) = '$Revision: 1.12 $' =~ / (\d+\.\d+) /;
+
+
+# Subject files, references and 
+# future "files affected part" (List the files being changed, plus the cvsweb URLs)
 
-# List of files for subject
+
+my $files_affected_part;
 my $subj_file_list="";
+my $references="";
+my $messageid="";
 for (my $i = 0; $i < @dirs; $i++) {
   my $dirs = $dirs[$i];
   my $dir = $dirs->{name};
   my $subdir = $dir;
   $subdir =~ s!^[^/]*/?!!;
   $subdir .= '/' if $subdir ne '';
-  if ($dirs[$i]->{type} ne 'directory') {
+
+  $files_affected_part = "$dir:\n";
+
+  if ($dirs[$i]->{type} eq 'directory') {
+    $files_affected_part = "   New directory\n";
+
+  } else {
     my $commits = $dirs->{commits};
+
     for (my $j = 0; $j < @$commits; $j++) {
       my $commit = $commits->[$j];
-      my $name = $commit->{name};
+      my ($name, $oldrev, $newrev, $op) = ($commit->{name}, $commit->{oldrev}, $commit->{newrev}, $commit->{op});
+      my $ref=$name.".".$oldrev;
+      $messageid="<".$name.".".$newrev.$messageid_email.">";
+      $files_affected_part = "   $name ($oldrev -> $newrev) ";
+      $files_affected_part = " (new)" if ($op eq 'add');
+      $files_affected_part = " (removed)" if ($op eq 'remove');
+      $files_affected_part = " (?! contact pasky)" if ($op eq '?');
+      $files_affected_part = "\n";
+      $files_affected_part = "    $cvsweb_url/$dir/$name?r1=$oldrev&r2=$newrev&f=u\n"
+        if defined $cvsweb_url and $op ne 'add' and $op ne 'remove';
       $subj_file_list.="$subdir$name, ";
+      $references.=" <". $ref. $messageid_email .">";
     }
   }
 }
 
-$subj_file_list =~ s/, $//;
-$subj =~ s/===FILES===/$subj_file_list/;
+# Fill in subj and possibly cut it
 
-$subj = substr($subj, 0, 75) . '...' if (length($subj) > 78);
+my ($subj);
+$subj_file_list =~ s/, $//;
+$subj = "Subject: [$project] $module".($tag?" ($tag)":"").": ".($subj_files?$subj_file_list:"").$logmsg;
+$subj =~ s/\n/ /g; $subj =~ s/ *$//;
+$subj = substr($subj, 0, $subj_maxlength-3) . '...' if (length($subj) > $subj_maxlength);
 
 print MAIL <<EOM;
 From: $from_email
@@ -309,66 +341,43 @@
 Reply-To: $reply_email
 Mail-Followup-To: $reply_email
 X-CVS: $user\@$project:$module
+X-CVS-Module: $module
 User-Agent: cvslog.pl/$VERSION
 $subj
+Message-ID: $messageid
+EOM
 
-$help_msg
-
-Author: $user
-Module: $module
-   Tag: $htag
-  Date: $date GMT
+if ($withthreading_email) {
+  print MAIL <<EOM;
+References: $references
+In-Reply-To: $references
 EOM
+}
+
+my $msgheder = "%-25s %45s\n%-36s %s", \
+	"Author: $user", "Date: $date GMT"\
+	"Module: $module","Tag: $htag";
 
 print MAIL <<EOM;
 
----- Log message:
+$msgheader
+EOM
 
+print MAIL <<EOM;
+---- Log message:
 $logmsg
 EOM
 
 print MAIL <<EOM;
-
 ---- Files affected:
-
+$files_affected_part
 EOM
 
 
-# List the files being changed, plus the cvsweb URLs
-
-for (my $i = 0; $i < @dirs; $i++) {
-  my $dirs = $dirs[$i];
-  my $dir = $dirs->{name};
-
-  print MAIL "$dir:\n";
-
-  if ($dirs[$i]->{type} eq 'directory') {
-    print MAIL "   New directory\n";
-
-  } else {
-    my $commits = $dirs->{commits};
-
-    for (my $j = 0; $j < @$commits; $j++) {
-      my $commit = $commits->[$j];
-      my ($name, $oldrev, $newrev, $op) = ($commit->{name}, $commit->{oldrev}, $commit->{newrev}, $commit->{op});
-      print MAIL "   $name ($oldrev -> $newrev) ";
-      print MAIL " (new)" if ($op eq 'add');
-      print MAIL " (removed)" if ($op eq 'remove');
-      print MAIL " (?! contact pasky)" if ($op eq '?');
-      print MAIL "\n";
-      print MAIL "    $cvsweb_url/$dir/$name?r1=$oldrev&r2=$newrev&f=u\n"
-        if defined $cvsweb_url and $op ne 'add' and $op ne 'remove';
-    }
-  }
-}
-
 goto end_diff unless $show_diff or $show_diffstat;
 
 print MAIL <<EOM;
-
-
 ---- Diffs:
-
 EOM
 
 
@@ -412,7 +421,7 @@
       }
     }
 
-    push (@diff, "\n\n" . ("=" x 64) . "\n");
+    push (@diff, "\n" . ("=" x 64) . "\n");
     push (@diff, @difflines);
   }
 }
@@ -434,7 +443,7 @@
     my @diffstat = <DIFFSTAT>;
     close DIFFSTAT;
     print MAIL @diffstat;
-    print MAIL "\n\n";
+    print MAIL "\n";
   }
   unlink ($dstmp);
 }


Więcej informacji o liście dyskusyjnej pld-devel-pl