]> git.donarmstrong.com Git - debbugs.git/commitdiff
[project @ 2002-09-25 16:16:55 by doogie]
authordoogie <>
Wed, 25 Sep 2002 23:16:55 +0000 (15:16 -0800)
committerdoogie <>
Wed, 25 Sep 2002 23:16:55 +0000 (15:16 -0800)
Modified to support db-h layout.

scripts/db2html.in

index 607e53f7f2b01d72dd88f10dc5279150029fb8b4..4c5e9efdd25a2b670ae4cc9429ce42f791f4c2a0 100755 (executable)
@@ -1,5 +1,5 @@
 #!/usr/bin/perl
-# $Id: db2html.in,v 1.8 2002/09/22 15:20:08 cjwatson Exp $
+# $Id: db2html.in,v 1.9 2002/09/25 16:16:55 doogie Exp $
 # usage: db2html [-diff] [-stampfile=<stampfile>] [-lastrun=<days>] <wwwbase>
 
 #load the necessary libraries/configuration
@@ -100,7 +100,7 @@ for $f (@files)
        #)
        # unless $ref =~ m/^-/ || $ref =~ m/^124/;
     &filelock("lock/$ref");
-    $preserveonly= defined($lastrun) && -M "db/$ref.log" > $lastrun;
+    $preserveonly= defined($lastrun) && -M "db-h/".get_hashname($ref)."/$ref.log" > $lastrun;
     if ($ref =~ m/^-\d$/) 
        {       $week= $ref eq '-1' ? 'this week' :
                $ref eq '-2' ? 'last week' :
@@ -125,7 +125,9 @@ for $f (@files)
         $tpackfile= "pnone.html";
         $indexpart= 'unmatched';
     } else 
-       {       open(S,"db/$ref.status") || &quit("open db/$ref.status: $!");
+       {
+       my $hash = get_hashname($ref);
+       open(S,"db-h/$hash/$ref.status") || &quit("open db-h/$hash/$ref.status: $!");
         chomp($s_originator= <S>);
         chomp($s_date= <S>);
         chomp($s_subject= <S>);
@@ -248,7 +250,8 @@ for $f (@files)
             &quit("eval add to \$perpack${indexpart}{\$tpack} failed: $@");
     }
     if ($preserveonly) { &preserve("$linkto.html"); &preserve("$linkto-b.html"); &unfilelock; next; }
-    open(L,"db/$ref.log") || &quit("open db/$ref.log: $!");
+    my $hash = get_hashname($ref);
+    open(L,"db-h/$hash/$ref.log") || &quit("open db-h/$hash/$ref.log: $!");
     $log='';
     $boring=''; $xmessage= 0;
     $normstate= 'kill-init';