summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-02-10 16:02:30 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-02-10 16:02:30 +0800
commit2ac73ee80d4213e163325f2597386043a27c9cc4 (patch)
tree0f01737d39b232c70c11cb6d647fbdf5e8b00566
parentc5380a4dde5ad35d86328dd745b4606a355b7844 (diff)
downloadpttbbs-2ac73ee80d4213e163325f2597386043a27c9cc4.tar
pttbbs-2ac73ee80d4213e163325f2597386043a27c9cc4.tar.gz
pttbbs-2ac73ee80d4213e163325f2597386043a27c9cc4.tar.bz2
pttbbs-2ac73ee80d4213e163325f2597386043a27c9cc4.tar.lz
pttbbs-2ac73ee80d4213e163325f2597386043a27c9cc4.tar.xz
pttbbs-2ac73ee80d4213e163325f2597386043a27c9cc4.tar.zst
pttbbs-2ac73ee80d4213e163325f2597386043a27c9cc4.zip
use $MAXIDX for path to index files
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@1524 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--sample/LocalVars.pm5
-rwxr-xr-xstaticweb/man.pl2
2 files changed, 6 insertions, 1 deletions
diff --git a/sample/LocalVars.pm b/sample/LocalVars.pm
index 70b4925f..e2b6b230 100644
--- a/sample/LocalVars.pm
+++ b/sample/LocalVars.pm
@@ -8,6 +8,7 @@ require Exporter;
$TAR $LYNX $GREP
$BLOGDATA $BLOGCACHE
$BLOGdbname $BLOGdbhost $BLOGdbuser $BLOGdbpasswd $BLOGdefault
+ $MANDATA $MANIDX $MANCACHE
/;
# host
@@ -38,4 +39,8 @@ $BLOGdbuser = 'root';
$BLOGdbpasswd = '';
$BLOGdefault = 'Blog';
+$MANDATA = '/home/web/ptt.man.data';
+$MANIDX = '/home/web/ptt.man.data';
+$MANCACHE = '/home/web/ptt.man.cache';
+
1;
diff --git a/staticweb/man.pl b/staticweb/man.pl
index 94e94640..661013fc 100755
--- a/staticweb/man.pl
+++ b/staticweb/man.pl
@@ -124,7 +124,7 @@ sub search($)
my($key) = @_;
my(%th, $idx, $k, $t0);
$t0 = [gettimeofday()];
- $idx = OurNet::FuzzyIndex->new("$MANDATA/$brdname.idx");
+ $idx = OurNet::FuzzyIndex->new("$MANIDX/$brdname.idx");
my %result = $idx->query($th{key} = $key, MATCH_FUZZY);
foreach my $t (sort { $result{$b} <=> $result{$a} } keys(%result)) {
$k = $idx->getkey($t);