unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Jani Nikula <jani@nikula.org>
To: notmuch@notmuchmail.org
Subject: [PATCH v2 2/2] emacs: Fix notmuch-mua-user-agent defcustom
Date: Tue, 20 Dec 2011 21:53:14 +0200	[thread overview]
Message-ID: <f57278c429382294021bd5e6959886a5e44af594.1324410479.git.jani@nikula.org> (raw)
In-Reply-To: <cover.1324410479.git.jani@nikula.org>
In-Reply-To: <cover.1324410479.git.jani@nikula.org>

The :options keyword is not meaningful for function type. Also, it was not
possible to enter nil value, contrary to the notmuch-mua-user-agent
defcustom documentation. Specify the alternatives using choice type, taking
nil into account.

Signed-off-by: Jani Nikula <jani@nikula.org>
---
 emacs/notmuch-mua.el |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el
index b525762..7114e48 100644
--- a/emacs/notmuch-mua.el
+++ b/emacs/notmuch-mua.el
@@ -35,10 +35,12 @@
   "Function used to generate a `User-Agent:' string. If this is
 `nil' then no `User-Agent:' will be generated."
   :group 'notmuch
-  :type 'function
-  :options '(notmuch-mua-user-agent-full
-	     notmuch-mua-user-agent-notmuch
-	     notmuch-mua-user-agent-emacs))
+  :type '(choice (const :tag "No user agent string" nil)
+		 (const :tag "Full" notmuch-mua-user-agent-full)
+		 (const :tag "Notmuch" notmuch-mua-user-agent-notmuch)
+		 (const :tag "Emacs" notmuch-mua-user-agent-emacs)
+		 (function :tag "Custom user agent function"
+			   :value notmuch-mua-user-agent-full)))
 
 (defcustom notmuch-mua-hidden-headers '("^User-Agent:")
   "Headers that are added to the `message-mode' hidden headers
-- 
1.7.5.4

  parent reply	other threads:[~2011-12-20 19:53 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-23 19:03 [PATCH 1/2] emacs: Fix notmuch-hello-tag-list-make-query defcustom Jani Nikula
2011-09-23 19:03 ` [PATCH 2/2] emacs: Fix notmuch-mua-user-agent defcustom Jani Nikula
2011-12-16 12:31   ` Dmitry Kurochkin
2011-12-16 12:22 ` [PATCH 1/2] emacs: Fix notmuch-hello-tag-list-make-query defcustom Dmitry Kurochkin
2011-12-16 12:29   ` Dmitry Kurochkin
2011-12-20 19:53 ` [PATCH v2 0/2] emacs: trivial defcustom fixes Jani Nikula
2011-12-20 19:53   ` [PATCH v2 1/2] emacs: Fix notmuch-hello-tag-list-make-query defcustom Jani Nikula
2011-12-22 11:34     ` David Bremner
2011-12-20 19:53   ` Jani Nikula [this message]
2011-12-21  8:51   ` [PATCH v2 0/2] emacs: trivial defcustom fixes David Edmondson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f57278c429382294021bd5e6959886a5e44af594.1324410479.git.jani@nikula.org \
    --to=jani@nikula.org \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).