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-ASN: X-Spam-Status: No, score=-4.0 required=3.0 tests=ALL_TRUSTED,AWL,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 97B3D1F462; Thu, 13 Jun 2019 08:07:39 +0000 (UTC) Date: Thu, 13 Jun 2019 08:07:39 +0000 From: Eric Wong To: Konstantin Ryabitsev Cc: meta@public-inbox.org Subject: Re: [PATCH 11/11] edit: new tool to perform edits Message-ID: <20190613080739.4lurodj6w6kkcsuh@dcvr> References: <20190609025147.24966-1-e@80x24.org> <20190609025147.24966-12-e@80x24.org> <20190610160610.GB16418@chatter.i7.local> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20190610160610.GB16418@chatter.i7.local> List-Id: Konstantin Ryabitsev wrote: > On Sun, Jun 09, 2019 at 02:51:47AM +0000, Eric Wong (Contractor, The Linux Foundation) wrote: > > +public-inbox-edit - edit messages in a public inbox > > + > > +=head1 SYNOPSIS > > + > > + public-inbox-edit -m MESSAGE-ID --all|INBOX_DIR > > + > > + public-inbox-edit -F RAW_FILE --all|INBOX_DIR [.. INBOX_DIR] > > A quick RFE that's beyond the scope of this work, but would be handy from > the usability perspective -- pass a search term in case multiple messages > need to be edited. E.g.: Fwiw, all this editing stuff gives me the heebie-jeebies. Not the code or tests itself, but users potentially shooting themselves (or other readers) in the foot and having to deal with it from a user support side... > public-inbox-edit -s "johndoe@example.com" INBOX_DIR > > The way I see it working, that would: > > 1. find all matching messages and put them into an mbox file So 1) is something I've been wanting to do for a long time, anyways. And I've got some optimizations in the pipeline (literally) which make sense for throughput-focused local usage. > 2. fire off "mutt -f" to start the editing session In my usage of mutt, I have to remind myself to purge the old message. It seemed like a bad usability hiccup, not sure if that'll be a problem for others... > 3. do a batch replace of all messages in the edited mbox file The backend part shouldn't be too hard. But mapping the mbox to the correct message gets a little tricky with support for ambiguous Message-IDs. But I think it'll be workable as long as the requirement of Message-IDs not being editable (or even reorderable) remains.