From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=ALL_TRUSTED,BAYES_00 shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id C7A8E1F9FC for ; Mon, 22 Mar 2021 07:54:02 +0000 (UTC) From: Eric Wong To: meta@public-inbox.org Subject: [PATCH 0/8] lei input handling improvements Date: Mon, 22 Mar 2021 07:53:54 +0000 Message-Id: <20210322075402.27834-1-e@80x24.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: lei share a bit more code, now; and being able to set "-c imap.debug" on the command-line should make future work easier. All this should set us up nicely for implementing "lei mark" to add/remove keywords and labels. Eric Wong (8): lei: support -c = to overrides net_reader: escape nasty chars from Net::NNTP->message lei: share input code between convert and import lei: simplify workers_start and callers mbox_reader: add ->reads method to avoid nonsensical formats lei_input: common filehandle reader for eml + mbox lei_input: drop "From " line on single "eml" (message/rfc822) lei import: ignore Status headers in "eml" messages MANIFEST | 1 + lib/PublicInbox/InboxWritable.pm | 2 +- lib/PublicInbox/LEI.pm | 137 ++++++++++++++++++------------- lib/PublicInbox/LeiConvert.pm | 94 ++++----------------- lib/PublicInbox/LeiExternal.pm | 2 +- lib/PublicInbox/LeiImport.pm | 107 +++++------------------- lib/PublicInbox/LeiInput.pm | 106 ++++++++++++++++++++++++ lib/PublicInbox/LeiP2q.pm | 4 +- lib/PublicInbox/MboxReader.pm | 5 ++ lib/PublicInbox/NetReader.pm | 10 ++- t/lei-import.t | 37 +++++++-- t/lei.t | 9 ++ 12 files changed, 278 insertions(+), 236 deletions(-) create mode 100644 lib/PublicInbox/LeiInput.pm