remove database and Hyper Estraier index before indexing
-=item --only=database_name
+=item --only=database_name/input_filter
reindex just single database (legacy name is --one)
+C</input_filter> is optional part which can be C<name>
+or C<type> from input
+
=item --config conf/config.yml
path to YAML configuration file
my $clean = 0;
my $config = 'conf/config.yml';
my $debug = 0;
-my $only_db_name;
+my $only_filter;
my $force_set = 0;
my $stats = 0;
"limit=i" => \$limit,
"offset=i" => \$offset,
"clean" => \$clean,
- "one=s" => \$only_db_name,
- "only=s" => \$only_db_name,
+ "one=s" => \$only_filter,
+ "only=s" => \$only_filter,
"config" => \$config,
"debug" => \$debug,
"force-set" => \$force_set,
while (my ($database, $db_config) = each %{ $config->{databases} }) {
- next if ($only_db_name && $database !~ m/$only_db_name/i);
+ my ($only_database,$only_input) = split(m#/#, $only_filter);
+ next if ($only_database && $database !~ m/$only_database/i);
my $indexer;
foreach my $input (@inputs) {
+ next if ($only_input && $input->{name} =~ m#$only_input#i || $input->{type} =~ m#$only_input#i);
+
my $type = lc($input->{type});
die "I know only how to handle input types ", join(",", @supported_inputs), " not '$type'!\n" unless (grep(/$type/, @supported_inputs));