$heading
+&print_html($header); +print <<"END"; + ++ i-scream CVS Commit Logs +
++ $heading +
++ $module module +
+END - print "\n$module module\n |
\n";
-
my(@lines) = `$logcmd $module 2>&1`;
if(@lines == 0) {
- print "There have been no commits in this module during this period.\n";
+ print <<"END";
+ + There have been no commits in this module during this period. + +END } else { + my(@log) = (); foreach my $line (@lines) { - if ($line =~ /^([0-9]{4}-[0-9]{2}-[0-9]{2}.*?)([^\s]+)$/) { - print "\n"; - print HTML_encode($1); - print ""; - print HTML_encode("by $2"); - print "\n" + if ($line =~ /^([0-9]{4}-[0-9]{2}-[0-9]{2}.*?)\s+([^\s]+)(\s+<([^\s]+)>)?$/) { + my($datetime) = escapeHTML($1); + my($committer) = escapeHTML($2); + my($email) = $4; + + if($sec != $secwho) { + if($sec == $seclog) { + @log = &trim_array(@log); + foreach my $logline (@log) { + $logline =~ s/^\t//; + print escapeHTML("$logline\n"); + } + @log = (); + print <<"END"; + + +END + } + if($firstentry) { + $firstentry = 0; + print <<"END"; +
+END
+ }
+ else {
+ print <<"END";
+
+END
+ }
+ $sec = $secwho;
+ }
+
+ print <<"END";
+
+END
+ }
}
- print "+ + $datetime + + committed by +END + if(defined $email) { + print <<"END"; + $committer +END + } + else { + print <<"END"; + $committer +END + } + print <<"END"; + +END } + elsif($line =~ /([^\s]+) (\([^,^\)]+(,[^\)]+)?\))([,:])/) { + my ($file, $rev, $tags, $ext) = ($1, $2, $3, $4); + $ext = escapeHTML($ext); + if($sec != $secfiles) { + $sec = $secfiles; + print <<"END"; +
+END
+ }
+ $file = escapeHTML($file);
+ print <<"END";
+ $file
+END
+ if($rev =~ /\(([^\s]+)\.(\d+)(.*)\)/) {
+ my $start = $1;
+ my $end = $2;
+ my $other = $3;
+ my $newrev = "$start.$end";
+ my $oldrev;
+ if($end != 1) {
+ my $oldminver = $end-1;
+ $oldrev = "$start.$oldminver";
+ }
+ elsif($start =~ /^((\d+\.)+)(\d+)$/) {
+ $oldrev = $1;
+ # take trailing . off old revision
+ chop $oldrev;
+ }
+ if(defined $oldrev) {
+ my $diff = ".diff?r1=$oldrev&r2=$newrev";
+ my $startend = escapeHTML("$start.$end");
+ $other = escapeHTML($other);
+ chomp $other;
+ print <<"END";
+ ($startend$other)$ext
+END
+ }
+ else {
+ $rev = escapeHTML($rev);
+ print <<"END";
+ $rev$ext
+END
+ }
+ }
+ else {
+ $rev = escapeHTML($rev);
+ print <<"END";
+ $rev$ext
+END
+ }
+ if($ext !~ /:$/) {
+ print <<"END";
+ +END + } + chomp $line; + push(@log, $line); } } + if($sec == $seclog) { + @log = &trim_array(@log); + foreach my $logline (@log) { + $logline =~ s/^\t//; + print escapeHTML("$logline\n"); + } + @log = (); + print <<"END"; ++ |
\n\n"; + print <<"END"; +