]> git.donarmstrong.com Git - debbugs.git/blobdiff - debian/debbugsconfig
include function in instalsql for bin ver/src pkg linking
[debbugs.git] / debian / debbugsconfig
index 9bb63c0758f13e58051f568cfe42fe6f98c76a51..e98decc7255d402110ff6e19daa4af8bc302a57f 100755 (executable)
@@ -4,9 +4,10 @@
 # Copyright (C) 1999 Darren Benham
 # Copyright (C) 2000 Josip Rodin
 # Licensed under the version 2 of the GNU General Public License as
-# published by the Free
+# published by the Free Software Foundation
 
 use POSIX qw(strftime);
+use File::Path;
 
 if (@ARGV) {
   print STDOUT <<EOF;
@@ -37,6 +38,12 @@ require "text";
 &template("nextnumber", $gSpoolDir);
 &touch("$gSpoolDir/index.archive.realtime");
 &touch("$gSpoolDir/index.db.realtime");
+print "Creating directories in $gSpoolDir:\n";
+for my $num (0 .. 99) {
+  &spooldirectory(sprintf('archive/%02d', $num));
+  &spooldirectory(sprintf('db-h/%02d', $num));
+}
+print "\n";
 
 # stuff used when testing (comment out the above)
 #unshift @INC, "../";
@@ -87,6 +94,14 @@ sub touch {
   }
 }
 
+sub spooldirectory {
+  my $name = shift;
+  unless (-d "$gSpoolDir/$name") {
+    mkpath("$gSpoolDir/$name");
+    print "$name ";
+  }
+}
+
 sub writefiles {
   local ($html, $text, $name) = @_;
 # first HTML