From: Austin Clements Date: Mon, 3 Dec 2012 22:13:14 +0000 (+1900) Subject: Re: [PATCH] emacs: drop support for deprecated notmuch-folders X-Git-Url: http://git.tremily.us/gitweb.cgi?a=commitdiff_plain;h=afee641b9e460d6ac20cf538c24b077d38012a60;p=notmuch-archives.git Re: [PATCH] emacs: drop support for deprecated notmuch-folders --- diff --git a/e4/5ea0ed4bb2fdfb78a4463359407ac6bfe1bac0 b/e4/5ea0ed4bb2fdfb78a4463359407ac6bfe1bac0 new file mode 100644 index 000000000..af81c7ce7 --- /dev/null +++ b/e4/5ea0ed4bb2fdfb78a4463359407ac6bfe1bac0 @@ -0,0 +1,157 @@ +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 E8F43431FBC + for ; Mon, 3 Dec 2012 14:13:22 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: -0.7 +X-Spam-Level: +X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 + tests=[RCVD_IN_DNSWL_LOW=-0.7] 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 nYhkSnk+40hO for ; + Mon, 3 Dec 2012 14:13:19 -0800 (PST) +Received: from dmz-mailsec-scanner-7.mit.edu (DMZ-MAILSEC-SCANNER-7.MIT.EDU + [18.7.68.36]) + by olra.theworths.org (Postfix) with ESMTP id 2F501431FC4 + for ; Mon, 3 Dec 2012 14:13:18 -0800 (PST) +X-AuditID: 12074424-b7fe06d0000008f0-92-50bd23fda783 +Received: from mailhub-auth-3.mit.edu ( [18.9.21.43]) + by dmz-mailsec-scanner-7.mit.edu (Symantec Messaging Gateway) with SMTP + id 99.B9.02288.DF32DB05; Mon, 3 Dec 2012 17:13:17 -0500 (EST) +Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) + by mailhub-auth-3.mit.edu (8.13.8/8.9.2) with ESMTP id qB3MDGE9030437; + Mon, 3 Dec 2012 17:13:17 -0500 +Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91]) + (authenticated bits=0) + (User authenticated as amdragon@ATHENA.MIT.EDU) + by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id qB3MDEcH011289 + (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); + Mon, 3 Dec 2012 17:13:15 -0500 (EST) +Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.80) + (envelope-from ) + id 1TfeGI-00043B-Dg; Mon, 03 Dec 2012 17:13:14 -0500 +Date: Mon, 3 Dec 2012 17:13:14 -0500 +From: Austin Clements +To: Jani Nikula +Subject: Re: [PATCH] emacs: drop support for deprecated notmuch-folders +Message-ID: <20121203221314.GG1020@mit.edu> +References: <1354569824-27213-1-git-send-email-jani@nikula.org> +MIME-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +Content-Disposition: inline +In-Reply-To: <1354569824-27213-1-git-send-email-jani@nikula.org> +User-Agent: Mutt/1.5.21 (2010-09-15) +X-Brightmail-Tracker: + H4sIAAAAAAAAA+NgFmpmleLIzCtJLcpLzFFi42IR4hTV1v2rvDfA4MEKdYum6c4W12/OZHZg + 8rh1/zW7x7NVt5gDmKK4bFJSczLLUov07RK4MqbcbWQvWCpRcevuVLYGxsXCXYycHBICJhJX + 1jcxQ9hiEhfurWfrYuTiEBLYxygx4/NTJghnPaPEv7MLWSGcC0wSS85MhSpbwihx8uIqJpB+ + FgEViT0bT4PNYhPQkNi2fzkjiC0ioCix+eR+MJtZQFri2+9msHphAXeJ7auug9XzCmhL3N7Q + wA5iCwnYS5yesYkVIi4ocXLmExaIXi2JG/9eAvVygM1Z/o8DJMwp4CDx+t5ZsDGiQCdMObmN + bQKj0Cwk3bOQdM9C6F7AyLyKUTYlt0o3NzEzpzg1Wbc4OTEvL7VI11wvN7NELzWldBMjKKzZ + XVR2MDYfUjrEKMDBqMTDO+HWngAh1sSy4srcQ4ySHExKorxSEnsDhPiS8lMqMxKLM+KLSnNS + iw8xSnAwK4nwvmYHyvGmJFZWpRblw6SkOViUxHmvp9z0FxJITyxJzU5NLUgtgsnKcHAoSfDW + KQE1ChalpqdWpGXmlCCkmTg4QYbzAA1fC1LDW1yQmFucmQ6RP8WoKCUOkRAASWSU5sH1wtLO + K0ZxoFeEebtBqniAKQuu+xXQYCagwS+EdoMMLklESEk1MOpIcpfXCquobGM96O2tJnbk1LGD + XxwP26U/mfEj0rX9rF1C5rbE9y7//V75q5U/1V3+QSVT/tHcmoh3XFciVedXL49NedEnf0X0 + u5ZfelOhkOqnd7/iKhzrEyPdaz50MHiq3+Qrq83YFRv9fgMf89+22rWWK9dvb5N83bloXapE + zsatHkuXKbEUZyQaajEXFScCADs2d4sWAwAA +Cc: notmuch@notmuchmail.org +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: Mon, 03 Dec 2012 22:13:23 -0000 + +LGTM. It's probably more reliable, too, since there are places where +we reference notmuch-saved-searches (the variable) directly that may +not pass through notmuch-hello first. + +Quoth Jani Nikula on Dec 03 at 11:23 pm: +> Remove notmuch-folders which has been deprecated since +> +> commit a4669217600e4536dc0c49f0255af5e2d9bc183f +> Author: Carl Worth +> Date: Mon Apr 26 22:42:07 2010 -0700 +> +> emacs: Rip out all of the notmuch-folder code. +> +> This lets us simplify the notmuch-saved-searches code slightly. +> --- +> emacs/notmuch-hello.el | 7 +------ +> emacs/notmuch-lib.el | 19 ++----------------- +> 2 files changed, 3 insertions(+), 23 deletions(-) +> +> diff --git a/emacs/notmuch-hello.el b/emacs/notmuch-hello.el +> index be50aae..6db62a0 100644 +> --- a/emacs/notmuch-hello.el +> +++ b/emacs/notmuch-hello.el +> @@ -689,7 +689,7 @@ following: +> "Show an entry for each saved search and inboxed messages for each tag" +> (notmuch-hello-insert-searches "What's in your inbox" +> (append +> - (notmuch-saved-searches) +> + notmuch-saved-searches +> (notmuch-hello-generate-tag-alist)) +> :filter "tag:inbox")) +> +> @@ -726,11 +726,6 @@ following: +> "Run notmuch and display saved searches, known tags, etc." +> (interactive) +> +> - ;; Jump through a hoop to get this value from the deprecated variable +> - ;; name (`notmuch-folders') or from the default value. +> - (unless notmuch-saved-searches +> - (setq notmuch-saved-searches (notmuch-saved-searches))) +> - +> (if no-display +> (set-buffer "*notmuch-hello*") +> (switch-to-buffer "*notmuch-hello*")) +> diff --git a/emacs/notmuch-lib.el b/emacs/notmuch-lib.el +> index 1d0ec17..3e8647d 100644 +> --- a/emacs/notmuch-lib.el +> +++ b/emacs/notmuch-lib.el +> @@ -77,7 +77,8 @@ +> (defvar notmuch-search-history nil +> "Variable to store notmuch searches history.") +> +> -(defcustom notmuch-saved-searches nil +> +(defcustom notmuch-saved-searches '(("inbox" . "tag:inbox") +> + ("unread" . "tag:unread")) +> "A list of saved searches to display." +> :type '(alist :key-type string :value-type string) +> :group 'notmuch-hello) +> @@ -96,22 +97,6 @@ For example, if you wanted to remove an \"inbox\" tag and add an +> :group 'notmuch-search +> :group 'notmuch-show) +> +> -(defvar notmuch-folders nil +> - "Deprecated name for what is now known as `notmuch-saved-searches'.") +> - +> -(defun notmuch-saved-searches () +> - "Common function for querying the notmuch-saved-searches variable. +> - +> -We do this as a function to support the old name of the +> -variable (`notmuch-folders') as well as for the default value if +> -the user hasn't set this variable with the old or new value." +> - (if notmuch-saved-searches +> - notmuch-saved-searches +> - (if notmuch-folders +> - notmuch-folders +> - '(("inbox" . "tag:inbox") +> - ("unread" . "tag:unread"))))) +> - +> (defun notmuch-version () +> "Return a string with the notmuch version number." +> (let ((long-string