From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 23947 invoked from network); 14 Feb 2021 22:19:54 -0000 Received: from 1ess.inri.net (216.126.196.35) by inbox.vuxu.org with ESMTPUTF8; 14 Feb 2021 22:19:54 -0000 Received: from outgoing.selfhost.de ([82.98.82.6]) by 1ess; Sun Feb 14 17:13:01 -0500 2021 Received: (qmail 2017 invoked from network); 14 Feb 2021 22:05:59 -0000 Received: from unknown (HELO mx03.bss-wf.de) (postmaster@emdtgvmf.mail.selfhost.de@84.150.39.186) by mailout.selfhost.de with ESMTPA; 14 Feb 2021 22:05:59 -0000 Received: by mx03.bss-wf.de (Postfix, from userid 1000) id 855933DD76; Sun, 14 Feb 2021 23:05:59 +0100 (CET) Received: from 9pi.pala (p5b3bcb58.dip0.t-ipconnect.de [91.59.203.88]) by mx03.bss-wf.de (Postfix) with ESMTPSA id 522163DD74 for <9front@9front.org>; Sun, 14 Feb 2021 23:05:58 +0100 (CET) Message-ID: <1E541693CE1BA38297468F967BA35FF2@bss-wf.de> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit To: 9front@9front.org Date: Sun, 14 Feb 2021 23:05:51 +0100 From: theinicke@bss-wf.de In-Reply-To: <092467A66CAF76198A34F2514264C1BC@eigenstate.org> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit List-ID: <9front.9front.org> List-Help: X-Glyph: ➈ X-Bullshit: optimized event-scale rails SVG markup rich-client database Subject: Re: [9front] Mail rewrite; open path with stored mails Reply-To: 9front@9front.org Precedence: bulk Thanks for the write-up. I appreciate it and get most of your points. Here are some notes regarding your comments: > Why not just make this flag modify the interpretation > of argv[0]? Frankly I do not get this - I thought about the new option behaving as opening the desired path at given name, if name is given via argv[0] (otherwise using last path component as name). > closembox()? removeopened is arguably not a nice name, however closembox would be imho not so good either, because we only close previously opened mbox and not in general > There's no real harm in skipping this special case. > It's one open in code that does an open for every > mail in the mailbox. What special case exactly? I thought that we may want to be able to open relative paths (for that I used fd2path(2)); this however would remove us from having the possibility to open another imap (/imaps/mailserver/...) directory - thus if the path is already absolute I decided to leave it as it is (except for 1 possibly trailing slash, as this happens likely; with multiple trailing slashes one may be doomed, but deserves it probably). > Why the termination and unterminaton? Arguably ugly - still use abspath below (read: extract last path component and leave absolute path intact).. > Why is this being repeated 10 times? [...] It tries with a modified mbox name each time - say you got something like $home/mail/9front/archive and $home/mail/9fans/archive Then upon invoking 'Mail -p $home/mail/9front/archive' you would get /mail/fs/archive and if you have this running somewhere and decided to open your other archive (without passing argument) this would be opened as /mail/fs/archive-0 That way we may have up to 11 mailboxes with the same name - 11 may be unnecessary high, but no harm I think? Taken from old Mail. The remaining comments point out some obvious flaws and I'll gladly fix them; just wanted to quickly leave this here and thanks again for the feedback