From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 12056429E30 for ; Sat, 14 Jan 2012 10:08:59 -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 w7MXGue5u+q7 for ; Sat, 14 Jan 2012 10:08:58 -0800 (PST) Received: from dmz-mailsec-scanner-5.mit.edu (DMZ-MAILSEC-SCANNER-5.MIT.EDU [18.7.68.34]) by olra.theworths.org (Postfix) with ESMTP id 60A82429E29 for ; Sat, 14 Jan 2012 10:08:58 -0800 (PST) X-AuditID: 12074422-b7fd66d0000008f9-9b-4f11c4b80e59 Received: from mailhub-auth-1.mit.edu ( [18.9.21.35]) by dmz-mailsec-scanner-5.mit.edu (Symantec Messaging Gateway) with SMTP id 16.5B.02297.8B4C11F4; Sat, 14 Jan 2012 13:08:56 -0500 (EST) Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) by mailhub-auth-1.mit.edu (8.13.8/8.9.2) with ESMTP id q0EI8kaH030804; Sat, 14 Jan 2012 13:08:47 -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 q0EI8Ujk015278 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT); Sat, 14 Jan 2012 13:08:45 -0500 (EST) Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.77) (envelope-from ) id 1Rm81k-0001wk-3C; Sat, 14 Jan 2012 13:08:28 -0500 Date: Sat, 14 Jan 2012 13:08:28 -0500 From: Austin Clements To: Pieter Praet Subject: Re: [PATCH] emacs: logically group def{custom,face}s Message-ID: <20120114180828.GD1801@mit.edu> References: <87ty3ypsgp.fsf@praet.org> <1326531898-17356-1-git-send-email-pieter@praet.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1326531898-17356-1-git-send-email-pieter@praet.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFuplleLIzCtJLcpLzFFi42IR4hRV1t1xRNDf4PAUfosbrd2MFtdvzmS2 +P36BrMDs8ezVbeYPTr2XWb12HLoPXMAcxSXTUpqTmZZapG+XQJXRk/jO7aCY9IVV3Y5NjC+ Fe1i5OSQEDCRuPhtKROELSZx4d56ti5GLg4hgX2MEvOuLWSHcDYwSsx8cgbKOckk8XE5SAuI s4RRouvgWWaQfhYBVYmdE9axgNhsAhoS2/YvZwSxRQSUJU4/+ckOYjML+ErM/fQDrF5YwFai bf0ksHpeAW2J5sZdYHEhgViJV7v6WCHighInZz5hgejVkrjx7yXQYg4gW1pi+T8OkDCngKPE +olbwMaLCqhITDm5jW0Co9AsJN2zkHTPQuhewMi8ilE2JbdKNzcxM6c4NVm3ODkxLy+1SNdU LzezRC81pXQTIyjU2V2UdjD+PKh0iFGAg1GJh7cwR8BfiDWxrLgy9xCjJAeTkijv+cOC/kJ8 SfkplRmJxRnxRaU5qcWHGCU4mJVEeO8tBsrxpiRWVqUW5cOkpDlYlMR51bXe+QkJpCeWpGan phakFsFkZTg4lCR47YExLSRYlJqeWpGWmVOCkGbi4AQZzgM03Bikhre4IDG3ODMdIn+KUVFK nFcUJCEAksgozYPrhaWiV4ziQK8I80qAVPEA0xhc9yugwUxAg8tS+EAGlyQipKQaGM3XnbF9 YlpxIcZt8qR7fu08t/qL+Uvf2Mixmj2wk1RYlxcdaPTY92rUomO3L363e3muJ8C/LGD9dhu3 kutTy7T5LH0vPXLcl9rn5TSPY8Fd1R8qO2ecFjM95H81ySaGaYlrJceOj+m94fufztCvjLD8 Xpk/43XRl1Obq1nnZBlGnWeddYLrtBJLcUaioRZzUXEiAPBH7UYgAwAA Cc: Notmuch Mail 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, 14 Jan 2012 18:08:59 -0000 Quoth Pieter Praet on Jan 14 at 10:04 am: > To allow for expansion whilst keeping everything tidy and organized, > move all defcustom/defface variables to the following subgroups, > defined in notmuch-lib.el: > > - Hello > - Search > - Show > - Send > - Crypto > - Hooks > - External Commands > - Appearance > > As an added benefit, defcustom keyword args are now consistently > in order of appearance @ defcustom's docstring (OCD much?). Thanks for doing this. I recently went into customize-group notmuch and was overwhelmed by the pile of options presented. > diff --git a/emacs/notmuch-lib.el b/emacs/notmuch-lib.el > index 0f856bf..f6f48e9 100644 > --- a/emacs/notmuch-lib.el > +++ b/emacs/notmuch-lib.el > @@ -28,17 +28,58 @@ > "Notmuch mail reader for Emacs." > :group 'mail) > Group docstrings aren't generally of the form "Options concerning ..."; they just jump into what they concern. E.g., Convenience : Convenience features for faster editing. Calendar Hooks : Calendar hooks. Also, all but one of the tags you give the groups would be automatically derived by Emacs, so you can remove those. > +(defgroup notmuch-hello nil > + "Options concerning `notmuch-hello-mode'." > + :tag "Notmuch Hello" > + :group 'notmuch) Perhaps "Overview of saved searches, tags, etc." > + > +(defgroup notmuch-search nil > + "Options concerning `notmuch-search-mode'." > + :tag "Notmuch Search" > + :group 'notmuch) "Searching and sorting mail"? > + > +(defgroup notmuch-show nil > + "Options concerning `notmuch-show-mode'." > + :tag "Notmuch Show" > + :group 'notmuch) "Showing messages and threads"? > + > +(defgroup notmuch-send nil > + "Options concerning the sending of messages." > + :tag "Notmuch Send" > + :group 'notmuch) "Sending messages from Notmuch"? We should probably link to the 'message group, perhaps by adding :link '(custom-group-link message) here or maybe to the notmuch group itself. Unfortunately, I don't think you can actually add a group to another group after it's been defined (though I could be wrong). > + > +(defgroup notmuch-crypto nil > + "Options concerning the processing and fontification of > +cryptographic MIME parts in `notmuch-show-mode'." > + :tag "Notmuch Crypto" > + :group 'notmuch) "Processing and display of cryptographic MIME parts"? (You also don't want the docstring to be too long, given how it's displayed.) > + > +(defgroup notmuch-hooks nil > + "Run custom code on well-defined occasions." > + :tag "Notmuch Hooks" > + :group 'notmuch) > + > +(defgroup notmuch-external nil > + "Run more custom code on different well-defined occasions." > + :tag "Notmuch External Commands" > + :group 'notmuch) Oof! It's okay to be a little redundant in the docstring. Core Emacs options do it. "External commands"? > + > +(defgroup notmuch-appearance nil > + "Options concerning how Notmuch looks." > + :tag "Notmuch Appearance" > + :group 'notmuch) "How Notmuch looks"? I worry that notmuch-appearance is a catch-all that most options arguably fit in to. In particular, some notmuch-show options are also in this group and some aren't and it's not clear to me what the rule is. Perhaps this should be notmuch-faces and limited to just faces (and maybe options that aren't technically faces but that affect face selection)? Then the grouping rule would be obvious, like it is for all of the other groups.