As far as the +word -word implementation, it
wouldn't be unreasonable to
add after the new query parser is wired in. I'd
even be glad to point
people in the right direction at that point. With the
current
htsearch/parser.cc, let's just say it's better to leave that mess
alone.
[Quim
Sanmarti]
Of course, an ad-hoc parser
would be the right thing, but in case of urgence, one could pre-process
av-style queries, replacing them by boolean style ones before passing them to
htsearch. Didn't someone do something similar to emulate Excite for Web
Servers with htdig? IIRC it was in the /contrib/ewswrap/ directory of the
htdig distribution.
A first approximation to
altavista-style queries would be, in htdig boolean syntax:
a b c +d +e +f -g -h -i == ((a or b
or c) and d and e and f ) not (g or h or i)
Strictly speaking, this is
not exactly what altavista would do; it would *rank* results containing
d&e&f but not g|h|i, ordered by a|b|c|d|e|f
relevance.
hth,
--
Quim