Skip to main content.
home | support | download

Back to List Archive

Re: Suggestion for recursive file search and bug fix for command line parser

From: Ron Klatchko <ron(at)>
Date: Thu Sep 02 1999 - 16:01:16 GMT
The architecture of SWISH-E allows for multiple access methods to be
defined.  Did you implement your code to take advantage of this?  This way
your version can happily coexist with the current version and the amount
of testing to verify that the old FS version works correctly would be
greatly reduced.

          Ron Klatchko - Manager, Advanced Technology Group           
           UCSF Library and Center for Knowledge Management           

On Wed, 1 Sep 1999, Ronald Aarts wrote:

> Dear everyone,
> I selected swish-e for use as a search engine at our site, but after playing 
> around with version 1.3 (most recent file dated March 18, 1999) I preferred to 
> add a feature which may be of use for others.
> At our site I did not want to index the complete root directory as users may 
> have some "hidden" files in their directory that I don't want to reveal with a 
> public accessible search engine. So I prefer to recursively process the files 
> starting with the first file(s) as specified. That is more or less the behavior of 
> the http-method of swish-e, but I want to use it for the fs-mode.
> To that order I modified 3 source files. In two cases the diffs with the originals 
> are small, but as the third is somewhat larger, I don't post them here. You can 
> find them at 
> In case that is a problem, let me know. This is what I did:
> * swish.h: 
>     Define a variable recursefiles with some constant values.
>     Define a structure pathlistentry.
> * swish.c:
>     Add two options -r and -R to select recusive fs-method (see e.g. in
>     usage().
>     Correct a few erroneous calls of argc-- in the case of command line
>     arguments processing (this is a bug in the original source!).
> * fs.c:
>     Complete overhaul for recursive processing, see the file.
> My modifications may not always be "optimal", but for the time being I am 
> quite satisfied with the result (including the original swish-e!). If you like my 
> suggestions, feel free to use them in your own version or perhaps even the 
> official version of swish-e.
> Of course, suggestions regarding my modifications are welcome.
> Regards,
Received on Thu Sep 2 08:57:58 1999