summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-07-03 22:01:36 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-07-03 22:01:36 +0800
commit44d3f81ae00d8428182460ef8c26dc646857a419 (patch)
tree4fba7c188d2acfe1fc2dee401ac68cc3be1a50f7
parent601cb25be39aa81ea7508c22281100f699c9494a (diff)
downloadpttbbs-44d3f81ae00d8428182460ef8c26dc646857a419.tar
pttbbs-44d3f81ae00d8428182460ef8c26dc646857a419.tar.gz
pttbbs-44d3f81ae00d8428182460ef8c26dc646857a419.tar.bz2
pttbbs-44d3f81ae00d8428182460ef8c26dc646857a419.tar.lz
pttbbs-44d3f81ae00d8428182460ef8c26dc646857a419.tar.xz
pttbbs-44d3f81ae00d8428182460ef8c26dc646857a419.tar.zst
pttbbs-44d3f81ae00d8428182460ef8c26dc646857a419.zip
bug fix
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk@1011 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rwxr-xr-xpttbbs/staticweb/manbuilder.pl8
1 files changed, 5 insertions, 3 deletions
diff --git a/pttbbs/staticweb/manbuilder.pl b/pttbbs/staticweb/manbuilder.pl
index ed15d57e..a6020357 100755
--- a/pttbbs/staticweb/manbuilder.pl
+++ b/pttbbs/staticweb/manbuilder.pl
@@ -1,5 +1,5 @@
#!/usr/bin/perl
-# $Id: manbuilder.pl,v 1.6 2003/07/03 13:38:53 in2 Exp $
+# $Id: manbuilder.pl,v 1.7 2003/07/03 14:01:36 in2 Exp $
use lib '/home/bbs/bin/';
use strict;
use OurNet::FuzzyIndex;
@@ -21,7 +21,8 @@ sub main
foreach( @ARGV ){
tie %db, 'DB_File', "$_.db", O_CREAT | O_RDWR, 0666, $DB_HASH;
- $idx = OurNet::FuzzyIndex->new("$_.idx");
+ $idx = OurNet::FuzzyIndex->new("$_.idx")
+ if( !$Getopt::Std::opt_n );
build("/home/bbs/man/boards/".substr($_, 0, 1)."/$_", '');
untie %db;
}
@@ -47,7 +48,8 @@ sub build($$)
push @tdir, ["$doffset/$fn",
$db{"title-$doffset/$fn"} = $bfh{"$_.title"}];
my $c = $bfh{"$_.content"};
- $idx->insert("$doffset/$fn", $bfh{"$_.title"}. "\n$c");
+ $idx->insert("$doffset/$fn", $bfh{"$_.title"}. "\n$c")
+ if( !$Getopt::Std::opt_n );
$db{"$doffset/$fn"} = $c;
}
}