]> Sergey Matveev's repositories - public-inbox.git/blobdiff - script/public-inbox-xcpdb
compact: reuse infrastructure from xcpdb
[public-inbox.git] / script / public-inbox-xcpdb
index 5b66337b47a10870543e599c80516bf84407c32f..bda7be0cadfb0192593679444de8c4aade0edb90 100755 (executable)
@@ -11,9 +11,8 @@ my $usage = "Usage: public-inbox-xcpdb INBOX_DIR\n";
 my $opt = {};
 GetOptions($opt, qw(compact quiet|q)) or die "bad command-line args\n$usage";
 my @ibxs = PublicInbox::Admin::resolve_inboxes(\@ARGV) or die $usage;
-my $cmd = [ \&PublicInbox::Xapcmd::cpdb ];
 foreach (@ibxs) {
        my $ibx = PublicInbox::InboxWritable->new($_);
        # we rely on --no-renumber to keep docids synched to NNTP
-       PublicInbox::Xapcmd::run($ibx, $cmd, undef, $opt);
+       PublicInbox::Xapcmd::run($ibx, 'cpdb', $opt);
 }