From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id aSSFIUUDjmMeBAEAbAwnHQ (envelope-from ) for ; Mon, 05 Dec 2022 15:42:13 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id YADkH0UDjmMrQAAAG6o9tA (envelope-from ) for ; Mon, 05 Dec 2022 15:42:13 +0100 Received: from mail.notmuchmail.org (yantan.tethera.net [135.181.149.255]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 2C6C41C0A9 for ; Mon, 5 Dec 2022 15:42:13 +0100 (CET) Received: from yantan.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id E12F35F9B3; Mon, 5 Dec 2022 14:42:10 +0000 (UTC) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by mail.notmuchmail.org (Postfix) with ESMTP id 3553F5F391 for ; Mon, 5 Dec 2022 14:42:08 +0000 (UTC) Received: by fethera.tethera.net (Postfix, from userid 1001) id 0689E5FB9E; Mon, 5 Dec 2022 09:42:06 -0500 (EST) Received: (nullmailer pid 1303050 invoked by uid 1000); Mon, 05 Dec 2022 14:42:05 -0000 From: David Bremner To: Greg Minshall , notmuch@notmuchmail.org Subject: Re: converting from nmh: how to? In-Reply-To: <778714.1670213178@archlinux> References: <778714.1670213178@archlinux> Date: Mon, 05 Dec 2022 10:42:05 -0400 Message-ID: <87h6y9kj42.fsf@tethera.net> MIME-Version: 1.0 Message-ID-Hash: CGSKFHQUYUHZQNM3AQMMZ7UANNLFYSAI X-Message-ID-Hash: CGSKFHQUYUHZQNM3AQMMZ7UANNLFYSAI X-MailFrom: david@tethera.net X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.3 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN X-Migadu-Country: DE ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1670251333; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-owner:list-unsubscribe:list-subscribe:list-post; bh=45QD/WgfnmxcHkZDh1Th362miWVWW48qUjelfUzPHzM=; b=FEGMjltdfOHVz0l9qRGntjiWtHh0ri7bbJDVhyp9D7MTQiofIJQqFJ6TeThflwPTbpdpZR XVbWeCJOeTmoN0q3Th20zdchfWEwm/jiw4FkcK+hM30Pr93HByY4f2e0uoMdKgGLnATYJl IdQOMBDv5uvmHe59H9cddSBzJna1M3jVCxAClV7JUdHLUtQdq/g3Fb3mpEuxMf3WaZo4nX ER5pA4WszXbnDUkqT+bVR/aGLjb/LBG1/NBsC+e+DjpK3ZEchgSwYNeTs51Vxi6RjxHFYy 5m96x2gb67gaIbSASAqaOZyMtA/iuLZutBh8ipfm9yJ46Ie7v82WrU1mb4P8iQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1670251333; a=rsa-sha256; cv=none; b=Jh3td157Cvq8GCXcHDfADOQp5Wvhk9C7GK4BRu8K3AmLzBaIpuIcVZKCyhvIVttUAZwk8g vk6qKyHH+HItcyi+ry5T7eo28vMDrDw+7G7wJ01PwskmwDqEOpdK410rYJBR9U+H4BnyYS EeXQAsB+zSy3QMFgQo78s+NJ4+Lapiyimk9TPajxmYPrp/CvIR0j7XRFcLmfJkrd/17c4R eXlW9aM3nDdolVXj+lH9lS5UPzhssnRMbrd58FkLidu8jybn/NyiYZYyK+KIzcvC3ev4dw CgjkCRhE1Fw4HwtPYqJb4pW8scM2SF3GvLl0ot9O+4fiSVYYuD1tHFrhP+uuNQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -0.61 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: 2C6C41C0A9 X-Spam-Score: -0.61 X-Migadu-Scanner: scn1.migadu.com X-TUID: Iatr9VMlsFQL Greg Minshall writes: > hi. apologies if this is an FAQ. > > i'm exploring notmuch (via the emacs front-end). i have 1.2M e-mail > messages sorted into 200 or so nmh folders. (*) > > after running `notmuch new`, i end up with 1.2M "unread" messages, all > in "inbox". > > i would like to end up with the "inbox" tag applied only to messages > actually in my nmh +inbox folder; messages from *other* nmh folders > should end up with a tag derived from that folder name. If I remember how mh works you should be able to use something like notmuch tag -inbox '*' notmuch tag +inbox path:relative/path/to/inbox/folder you may want to use "notmuch dump > backup.tags" before some bold experiments. > and, i would like to have the "unread" tag only apply to messages that > nmh thinks are unseen. > > (iiuc, nmh keeps track of unseen messages in ".mh_sequences" local to > each nmh folder; i don't think i care about any other sequences, > including "cur", in any of the ".mh_sequences" files.) > > is there a known procedure for accomplishing this? or, thoughts on > same? notmuch does not index filenames, so that makes things a bit more challenging. With a little scripting, you could extract the message-id for message 'n' and pass that to notmuch. I'd probably write a python script (and use the 'notmuch2' module), but it's doable as a shell script also (given some hack to extract the message-id).