OSSP CVS Repository

ossp - Check-in [50]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 50
Date: 2000-Jun-17 16:33:23 (local)
2000-Jun-17 14:33:23 (UTC)
User:rse
Branch:
Comment: Update Shiela to 0.9.0
Tickets:
Inspections:
Files:
CVSROOT/shiela      1.3 -> 1.4     18 inserted, 20 deleted

CVSROOT/shiela 1.3 -> 1.4

--- shiela       2000/06/17 12:40:28     1.3
+++ shiela       2000/06/18 14:33:23     1.4
@@ -172,12 +172,10 @@
         }
         return $prog;
     }
-    $RT->{sendmail} = $CF->{Environment}->{Sendmail} ||
-                      &find_program("ssmtp") ||
+    $RT->{sendmail} = &find_program("ssmtp") ||
                       &find_program("sendmail") || 
                       die "unable to find `sendmail' program";
-    $RT->{cvs}      = $CF->{Environment}->{CVS} ||
-                      &find_program("cvs") || 
+    $RT->{cvs}      = &find_program("cvs") || 
                       die "unable to find `cvs' program";
 
     #   pre-calculate a reasonable MIME boundary tag
@@ -370,8 +368,6 @@
     #   in parallel (through a callback function) create the final
     #   configuration structure.
     my $CF = {
-        'Environment' => {
-        },
         'Project' => {
             'User' => {},
             'Group' => {}
@@ -386,7 +382,7 @@
     my $cf = &parse_config($t, \&parse_config_callback, $CF);
     sub parse_config_callback {
         my ($CF, $action, $level, $cf) = @_;
-        if ($action eq 'CMD' and $cf->[0] =~ m/(Environment|Project|Repository|Logging)/) {
+        if ($action eq 'CMD' and $cf->[0] =~ m/(Project|Repository|Logging)/) {
             my $a;
             foreach $a (@{$cf->[1]}) {
                 $CF->{$1}->{$a->[0]} = $a->[1] 
@@ -997,7 +993,7 @@
         print "cvs tag: Access Denied - Insufficient Karma!\n"; 
         print "cvs tag: Tagging access for the following file(s) was denied:\n";
         foreach my $file (@denyfiles) {
-            print "cvs tag:     `$file'\n";
+            print "cvs tag: `$file'\n";
         }
         print "cvs tag: Contact <".$CF->{Repository}->{Contact}."> for details.\n";
 
@@ -1054,7 +1050,7 @@
         print "cvs admin: Access Denied - Insufficient Karma!\n"; 
         print "cvs admin: Admin access for the following file(s) was denied:\n";
         foreach my $file (@denyfiles) {
-            print "cvs admin:     `$file'\n";
+            print "cvs admin: `$file'\n";
         }
         print "cvs admin: Contact <".$CF->{Repository}->{Contact}."> for details.\n";
 
@@ -1110,7 +1106,7 @@
         print "cvs import: Access Denied - Insufficient Karma!\n"; 
         print "cvs import: Import access for the following files was denied:\n";
         foreach my $file (@denyfiles) {
-            print "cvs import:     `$file'\n";
+            print "cvs import: `$file'\n";
         }
         print "cvs import: Contact <".$CF->{Repository}->{Contact}."> for details.\n";
 
@@ -1206,7 +1202,7 @@
         print "cvs commit: Access Denied - Insufficient Karma!\n"; 
         print "cvs commit: Commit access for the following file(s) was denied:\n";
         foreach my $file (@denyfiles) {
-            print "cvs commit:     `$file'\n";
+            print "cvs commit: `$file'\n";
         }
         print "cvs commit: Contact <".$CF->{Repository}->{Contact}."> for details.\n";
 
@@ -1392,9 +1388,6 @@
             elsif ($Io eq 'T') { $Io = 'T'; }
 
             #   determine revisions
-            my $subdir = $Is;
-            $subdir =~ s|/?[^/]+$||;
-            $subdir =~ s|^$|.|;
             my $rcslog = '';
             if (not $RT->{useserver}) {
                 if (not -d './CVS') {
@@ -1415,9 +1408,13 @@
             }
             else {
                 my $cvs = new CVS ($RT->{cvs}, $RT->{cvsroot});
-                $cvs->directory($cvsdir);
-                $cvs->entry($Is);
-                $cvs->arguments("-r$It", $Is);
+                my ($subdir, $file) = ($cvsdir, $Is);
+                if ($file =~ m|^(.+)/([^/]+)$|) {
+                    ($subdir, $file) = ($subdir."/".$1, $2);
+                }
+                $cvs->directory($subdir);
+                $cvs->entry($file);
+                $cvs->arguments("-r$It", $file);
                 $cvs->send("log");
                 $rcslog = scalar $cvs->result;
                 $cvs->close;
@@ -1563,8 +1560,7 @@
                 $Id = sprintf("+%d/-%d", ($Io eq 'A' ? $l : 0), ($Io eq 'A' ? 0 : $l));
             }
             elsif ($Io eq 'M') {
-                # if ($rcslog =~ m|\ndate:.*lines:\s*(.+?)\s*\n|s) {
-                if ($rcslog =~ m|\ndate:.*lines:\s*([\d \t-]+)|s) {
+                if ($rcslog =~ m|\ndate:.*lines:\s*([\d \t+-]+)|s) {
                     $Id = $1;
                     $Id =~ s|\s+|/|g;
                 }
@@ -1999,7 +1995,9 @@
                                           $IN->{file}->{$file}->{newrev}, 
                                           $IN->{file}->{$file}->{delta});
                 next if ($op eq 'T');
-                $delta =~ s|/| |g;
+                if ($delta =~ m|^(.+)/(.+)$|) {
+                    $delta = sprintf("%-3s %-3s", $1, $2);
+                }
                 $O .= $prefix.sprintf("  %-12s%-12s%s\n", $rev, $delta, $file);
             }
         }

CVSTrac 2.0.1