From b116c64fb8c1f3df3687ca6175cb0bb4a0ee044c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=BCdiger=20Sonderfeld?= Date: Sat, 25 Aug 2012 13:16:54 +0200 Subject: [PATCH] mu4e-utils: Password query string as variable. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Added `mu4e~get-mail-ask-password' instead of a simply "Password: " prompt. Signed-off-by: RĂ¼diger Sonderfeld --- mu4e/mu4e-utils.el | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/mu4e/mu4e-utils.el b/mu4e/mu4e-utils.el index d1e78275..a5a562e7 100644 --- a/mu4e/mu4e-utils.el +++ b/mu4e/mu4e-utils.el @@ -682,6 +682,9 @@ FUNC (if non-nil) afterwards." (defconst mu4e~update-mail-name "*mu4e-update-mail*" "Name of the process to update mail.") +(defvar mu4e~get-mail-ask-password "mu4e get-mail: Enter password: " + "Query string for `mu4e-get-mail-command' password.") + (defvar mu4e~get-mail-password-regexp "^Remote: Enter password: $" "Regexp to match a password query in the `mu4e-get-mail-command' output.") @@ -695,7 +698,9 @@ into the process buffer." (let ((inhibit-read-only t)) ;; Check whether process asks for a password and query user (when (string-match mu4e~get-mail-password-regexp msg) - (process-send-string proc (concat (read-passwd "Password: ") "\n"))) + (process-send-string proc (concat + (read-passwd mu4e~get-mail-ask-password) + "\n"))) (insert msg)))) (defun mu4e-update-mail (&optional buf)