use strict;
use lib '.';
use open OUT => ':utf8';
use WWW::SherlockSearch;

die "Usage: $0 template_file [ query_string [ max_results ] ]\n" unless @ARGV;

my $sourcefile = -f $ARGV[0] ? $ARGV[0] : "plugins/$ARGV[0]";
my $infoSearch = WWW::SherlockSearch->new;


my $results = $infoSearch->find($ARGV[1], $ARGV[2]);
print $infoSearch->resultsAsRssString if $results;


=head1 NAME

sherch - Sherlock Searcher


    # search 'perl' in google, return top five hits as RSS
    % sherch google.src perl 5


This program executes a sherlock search and returns the result as
a RSS string.

=head1 AUTHORS

Autrijus Tang E<lt>autrijus@autrijus.orgE<gt>


Copyright 2002 by Autrijus Tang E<lt>autrijus@autrijus.orgE<gt>.

This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.

See L<http://www.perl.com/perl/misc/Artistic.html>