about summary refs log tree commit homepage
path: root/script/public-inbox-index
diff options
context:
space:
mode:
authorEric Wong <e@yhbt.net>2020-08-10 02:11:52 +0000
committerEric Wong <e@yhbt.net>2020-08-10 05:50:59 +0000
commit03d2ebbcde99903bd84d3fd0c2815edc28ee3acf (patch)
tree7fdb3774a74b3a7fca834e214d646428d8dfe868 /script/public-inbox-index
parentc538c9593e4c4d8185c3131eab2d14c383fafe8f (diff)
downloadpublic-inbox-03d2ebbcde99903bd84d3fd0c2815edc28ee3acf.tar.gz
This to avoid user error of a currently undocumented switch;
since --xapian-only always goes through the full history at
the moment.
Diffstat (limited to 'script/public-inbox-index')
-rwxr-xr-xscript/public-inbox-index3
1 files changed, 3 insertions, 0 deletions
diff --git a/script/public-inbox-index b/script/public-inbox-index
index 73ca2953..9e0907be 100755
--- a/script/public-inbox-index
+++ b/script/public-inbox-index
@@ -42,6 +42,9 @@ GetOptions($opt, qw(verbose|v+ reindex rethread compact|c+ jobs|j=i prune
         or die "bad command-line args\n$usage";
 if ($opt->{help}) { print $help; exit 0 };
 die "--jobs must be >= 0\n" if defined $opt->{jobs} && $opt->{jobs} < 0;
+if ($opt->{xapianonly} && !$opt->{reindex}) {
+        die "--xapian-only requires --reindex\n";
+}
 
 # require lazily to speed up --help
 require PublicInbox::Admin;