Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 17A8142D287 for ; Sat, 15 Jan 2011 14:46:58 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -1 X-Spam-Level: X-Spam-Status: No, score=-1 tagged_above=-999 required=5 tests=[ALL_TRUSTED=-1] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ctkt6oka8huJ for ; Sat, 15 Jan 2011 14:46:57 -0800 (PST) Received: from yoom.home.cworth.org (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 4E1B442D286 for ; Sat, 15 Jan 2011 14:46:55 -0800 (PST) Received: by yoom.home.cworth.org (Postfix, from userid 1000) id 987F6254007; Sat, 15 Jan 2011 14:46:53 -0800 (PST) From: Carl Worth To: notmuch@notmuchmail.org Subject: Folder-based searching User-Agent: Notmuch/0.5 (http://notmuchmail.org) Emacs/23.2.1 (i486-pc-linux-gnu) Date: Sat, 15 Jan 2011 14:46:53 -0800 Message-ID: <87tyh9wzs2.fsf@yoom.home.cworth.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 22:46:58 -0000 I'm as sad as anyone to see that I let more than a month go by without committing to the notmuch repository. But I've just now committed the much-desired folder-based search feature. This should be a handy feature for people bringing mail in from a system that stores information in the directories in which mail is stored, (one common case is users fetching mail from gmail via imap---in this case all gmail tags will be represented as directories). Someone bringing in mail from such a system might want to migrate from information in directory names to instead be information in notmuch tags. That might look something like this: notmuch tag +important folder:important Or it might be useful to run on several directories: for dir in *; do notmuch tag +"$dir"; folder:"$dir"; done etc. Please note that with the code in git currently, only newly incorporated mail will be searchable via the "folder:" specification. So if you're wanting to search your entire email collection, you may want to rebuild your entire notmuch database. As a reminder, that process is something like the following: notmuch dump > notmuch.dump rm -rf ~/mail/.notmuch # Careful with this! Have backups in place! notmuch new # Of course, this can take a long time notmuch restore notmuch.dump Before the next release, I plan to increment the database version so that users will be notified of the need to do an upgrade like this. (But before I do that, I plan to implement a few more database changes---and some of them are likely to be much more invasive than this one). Have fun out there! -Carl