summaryrefslogtreecommitdiff
path: root/lisp/mh-e
diff options
context:
space:
mode:
authorBill Wohler <wohler@newt.com>2006-01-04 02:08:12 +0000
committerBill Wohler <wohler@newt.com>2006-01-04 02:08:12 +0000
commitf9c53c973d9f182683fee67a5ce6ca8bc7bd51a7 (patch)
tree409ddb5ec337600471777514241015b50e320ca0 /lisp/mh-e
parent078cb3146bd2c659c3f2b9b55f401b73da77e6dc (diff)
downloademacs-f9c53c973d9f182683fee67a5ce6ca8bc7bd51a7.tar.gz
emacs-f9c53c973d9f182683fee67a5ce6ca8bc7bd51a7.tar.bz2
emacs-f9c53c973d9f182683fee67a5ce6ca8bc7bd51a7.zip
* mh-alias.el (mh-alias-add-alias): Grand message and error string
unification. Use single sentence if possible by using semicolon. Don't end message with punctuation. Don't need format with message. Quote messages as in docstrings: use `' around symbols, \" for option choices. Don't use quotes around %s. * mh-comp.el (mh-complete-word): Ditto. * mh-customize.el (mh-adaptive-cmd-note-flag-check) (mh-scan-format-file-check): Ditto. * mh-e.el (mh-refile-or-write-again, mh-previous-unread-msg) (mh-delete-a-msg, mh-refile-a-msg, mh-next-unread-msg) (mh-msg-num-width-to-column): Ditto. * mh-identity.el (mh-identity-field-handler): Ditto. * mh-index.el (mh-mairix-execute-search) (mh-swish-execute-search, mh-swish++-execute-search) (mh-namazu-execute-search): Ditto. * mh-init.el (mh-variant-set): Ditto. * mh-mime.el (mh-mh-to-mime-undo, mh-mml-forward-message) (mh-secure-message, mh-mime-display): Ditto. * mh-pick.el (mh-search-folder, mh-pick-construct-regexp): Ditto. * mh-seq.el (mh-narrow-to-seq, mh-put-msg-in-seq, mh-read-seq) (mh-read-range, mh-thread-container-subject): Ditto. * mh-utils.el (mh-x-image-scale-and-display) (mh-prompt-for-folder, mh-handle-process-error) (mh-list-to-string-1): Ditto.
Diffstat (limited to 'lisp/mh-e')
-rw-r--r--lisp/mh-e/ChangeLog35
-rw-r--r--lisp/mh-e/mh-alias.el2
-rw-r--r--lisp/mh-e/mh-comp.el2
-rw-r--r--lisp/mh-e/mh-customize.el4
-rw-r--r--lisp/mh-e/mh-e.el17
-rw-r--r--lisp/mh-e/mh-identity.el4
-rw-r--r--lisp/mh-e/mh-index.el8
-rw-r--r--lisp/mh-e/mh-init.el6
-rw-r--r--lisp/mh-e/mh-mime.el10
-rw-r--r--lisp/mh-e/mh-pick.el4
-rw-r--r--lisp/mh-e/mh-seq.el10
-rw-r--r--lisp/mh-e/mh-utils.el8
12 files changed, 72 insertions, 38 deletions
diff --git a/lisp/mh-e/ChangeLog b/lisp/mh-e/ChangeLog
index e0da0950715..b679c78479c 100644
--- a/lisp/mh-e/ChangeLog
+++ b/lisp/mh-e/ChangeLog
@@ -1,5 +1,40 @@
2006-01-03 Bill Wohler <wohler@newt.com>
+ * mh-alias.el (mh-alias-add-alias): Grand message and error string
+ unification. Use single sentence if possible by using semicolon.
+ Don't end message with punctuation. Don't need format with
+ message. Quote messages as in docstrings: use `' around symbols,
+ \" for option choices. Don't use quotes around %s.
+
+ * mh-comp.el (mh-complete-word): Ditto.
+
+ * mh-customize.el (mh-adaptive-cmd-note-flag-check)
+ (mh-scan-format-file-check): Ditto.
+
+ * mh-e.el (mh-refile-or-write-again, mh-previous-unread-msg)
+ (mh-delete-a-msg, mh-refile-a-msg, mh-next-unread-msg)
+ (mh-msg-num-width-to-column): Ditto.
+
+ * mh-identity.el (mh-identity-field-handler): Ditto.
+
+ * mh-index.el (mh-mairix-execute-search)
+ (mh-swish-execute-search, mh-swish++-execute-search)
+ (mh-namazu-execute-search): Ditto.
+
+ * mh-init.el (mh-variant-set): Ditto.
+
+ * mh-mime.el (mh-mh-to-mime-undo, mh-mml-forward-message)
+ (mh-secure-message, mh-mime-display): Ditto.
+
+ * mh-pick.el (mh-search-folder, mh-pick-construct-regexp): Ditto.
+
+ * mh-seq.el (mh-narrow-to-seq, mh-put-msg-in-seq, mh-read-seq)
+ (mh-read-range, mh-thread-container-subject): Ditto.
+
+ * mh-utils.el (mh-x-image-scale-and-display)
+ (mh-prompt-for-folder, mh-handle-process-error)
+ (mh-list-to-string-1): Ditto.
+
* mh-comp.el (mh-reply): Use standard default notation in
prompts (closes SF #1275933).
diff --git a/lisp/mh-e/mh-alias.el b/lisp/mh-e/mh-alias.el
index 7349f556224..a1bafb3ec51 100644
--- a/lisp/mh-e/mh-alias.el
+++ b/lisp/mh-e/mh-alias.el
@@ -571,7 +571,7 @@ filing messages."
(cond
((and (equal alias address-alias)
(equal address alias-address))
- (message "Already defined as: %s" alias-address))
+ (message "Already defined as %s" alias-address))
(address-alias
(if (y-or-n-p (format "Address has alias %s; set new one? "
address-alias))
diff --git a/lisp/mh-e/mh-comp.el b/lisp/mh-e/mh-comp.el
index ddab3725058..9a4c8733959 100644
--- a/lisp/mh-e/mh-comp.el
+++ b/lisp/mh-e/mh-comp.el
@@ -1818,7 +1818,7 @@ Any match found replaces the text from BEGIN to END."
((null completion)
(ignore-errors
(kill-buffer completions-buffer))
- (message "No completion for `%s'" word))
+ (message "No completion for %s" word))
((stringp completion)
(if (equal word completion)
(with-output-to-temp-buffer completions-buffer
diff --git a/lisp/mh-e/mh-customize.el b/lisp/mh-e/mh-customize.el
index f4cde0b186f..01b03db63f9 100644
--- a/lisp/mh-e/mh-customize.el
+++ b/lisp/mh-e/mh-customize.el
@@ -1041,7 +1041,7 @@ Throw an error if user tries to turn on
Otherwise, set SYMBOL to VALUE."
(if (and value
(not (eq mh-scan-format-file t)))
- (error "%s %s" "Can't turn on unless mh-scan-format-file"
+ (error "%s %s" "Can't turn on unless `mh-scan-format-file'"
"is set to \"Use MH-E scan Format\"")
(set-default symbol value)))
@@ -1052,7 +1052,7 @@ anything but t when `mh-adaptive-cmd-note-flag' is on. Otherwise,
set SYMBOL to VALUE."
(if (and (not (eq value t))
(eq mh-adaptive-cmd-note-flag t))
- (error "%s %s" "You must turn off mh-adaptive-cmd-note-flag"
+ (error "%s %s" "You must turn off `mh-adaptive-cmd-note-flag'"
"unless you use \"Use MH-E scan Format\"")
(set-default symbol value)))
diff --git a/lisp/mh-e/mh-e.el b/lisp/mh-e/mh-e.el
index 19024ffc6f6..f1712f7b92c 100644
--- a/lisp/mh-e/mh-e.el
+++ b/lisp/mh-e/mh-e.el
@@ -904,8 +904,7 @@ called interactively."
(error "No previous refile or write"))
(cond ((eq (car mh-last-destination) 'refile)
(mh-refile-msg range (cdr mh-last-destination))
- (message "%s" (format "Destination folder: %s"
- (cdr mh-last-destination))))
+ (message "Destination folder: %s" (cdr mh-last-destination)))
(t
(mh-iterate-on-range msg range
(apply 'mh-write-msg-to-file msg (cdr mh-last-destination)))
@@ -1005,7 +1004,7 @@ This command can be given a prefix argument COUNT to specify how
many unread messages to skip."
(interactive "p")
(unless (> count 0)
- (error "The function mh-previous-unread-msg expects positive argument"))
+ (error "The function `mh-previous-unread-msg' expects positive argument"))
(setq count (1- count))
(let ((unread-sequence (cdr (assoc mh-unseen-seq mh-seq-list)))
(cur-msg (mh-get-msg-num nil)))
@@ -1527,7 +1526,7 @@ once when he kept statistics on his mail usage."
(beginning-of-line)
(setq message (mh-get-msg-num t)))
(if (looking-at mh-scan-refiled-msg-regexp)
- (error "Message %d is refiled. Undo refile before deleting" message))
+ (error "Message %d is refiled; undo refile before deleting" message))
(if (looking-at mh-scan-deleted-msg-regexp)
nil
(mh-set-folder-modified-p t)
@@ -1547,10 +1546,10 @@ be refiled."
(beginning-of-line)
(setq message (mh-get-msg-num t)))
(cond ((looking-at mh-scan-deleted-msg-regexp)
- (error "Message %d is deleted. Undo delete before moving" message))
+ (error "Message %d is deleted; undo delete before moving" message))
((looking-at mh-scan-refiled-msg-regexp)
(if (y-or-n-p
- (format "Message %d already refiled. Copy to %s as well? "
+ (format "Message %d already refiled; copy to %s as well? "
message folder))
(mh-exec-cmd "refile" (mh-get-msg-num t) "-link"
"-src" mh-current-folder
@@ -1581,7 +1580,7 @@ This command can be given a prefix argument COUNT to specify how
many unread messages to skip."
(interactive "p")
(unless (> count 0)
- (error "The function mh-next-unread-msg expects positive argument"))
+ (error "The function `mh-next-unread-msg' expects positive argument"))
(setq count (1- count))
(let ((unread-sequence (reverse (cdr (assoc mh-unseen-seq mh-seq-list))))
(cur-msg (mh-get-msg-num nil)))
@@ -1989,8 +1988,8 @@ columns contain the message number, and the column for notations
comes after that."
(if (eq mh-scan-format-file t)
(max (1+ width) 2)
- (error "%s %s" "Can't call mh-msg-num-width-to-column"
- "when mh-scan-format-file is not t")))
+ (error "%s %s" "Can't call `mh-msg-num-width-to-column' when"
+ "`mh-scan-format-file' is not set to \"Use MH-E scan Format\"")))
(defun mh-set-cmd-note (column)
"Set `mh-cmd-note' to COLUMN.
diff --git a/lisp/mh-e/mh-identity.el b/lisp/mh-e/mh-identity.el
index 52bb8f903fe..1af2563eeda 100644
--- a/lisp/mh-e/mh-identity.el
+++ b/lisp/mh-e/mh-identity.el
@@ -1,6 +1,6 @@
;;; mh-identity.el --- Multiple identify support for MH-E.
-;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Peter S. Galbraith <psg@debian.org>
;; Maintainer: Bill Wohler <wohler@newt.com>
@@ -127,7 +127,7 @@ character \":\", then it must have a special handler defined in
valid header field."
(or (cdr (mh-assoc-ignore-case field mh-identity-handlers))
(and (eq (aref field 0) ?:)
- (error "Field %s - unknown mh-identity-handler" field))
+ (error "Field %s not found in `mh-identity-handlers'" field))
(cdr (assoc ":default" mh-identity-handlers))
'mh-identity-handler-default))
diff --git a/lisp/mh-e/mh-index.el b/lisp/mh-e/mh-index.el
index 08775c557b1..787acc35333 100644
--- a/lisp/mh-e/mh-index.el
+++ b/lisp/mh-e/mh-index.el
@@ -1168,7 +1168,7 @@ SEARCH-REGEXP-LIST is used to search."
(set-buffer (get-buffer-create mh-index-temp-buffer))
(erase-buffer)
(unless mh-mairix-binary
- (error "Set mh-mairix-binary appropriately"))
+ (error "Set `mh-mairix-binary appropriately'"))
(apply #'call-process mh-mairix-binary nil '(t nil) nil
"-r" "-f" (format "%s%s/config" mh-user-path mh-mairix-directory)
search-regexp-list)
@@ -1446,7 +1446,7 @@ is used to search."
(set-buffer (get-buffer-create mh-index-temp-buffer))
(erase-buffer)
(unless mh-swish-binary
- (error "Set mh-swish-binary appropriately"))
+ (error "Set `mh-swish-binary' appropriately"))
(call-process mh-swish-binary nil '(t nil) nil
"-w" search-regexp
"-f" (format "%s%s/index" mh-user-path mh-swish-directory))
@@ -1535,7 +1535,7 @@ used to search."
(set-buffer (get-buffer-create mh-index-temp-buffer))
(erase-buffer)
(unless mh-swish++-binary
- (error "Set mh-swish++-binary appropriately"))
+ (error "Set `mh-swish++-binary' appropriately"))
(call-process mh-swish++-binary nil '(t nil) nil
"-m" "10000"
(format "-i%s%s/swish++.index"
@@ -1614,7 +1614,7 @@ is used to search."
(unless (file-exists-p namazu-index-directory)
(error "Namazu directory %s not present" namazu-index-directory))
(unless (executable-find mh-namazu-binary)
- (error "Set mh-namazu-binary appropriately"))
+ (error "Set `mh-namazu-binary' appropriately"))
(set-buffer (get-buffer-create mh-index-temp-buffer))
(erase-buffer)
(call-process mh-namazu-binary nil '(t nil) nil
diff --git a/lisp/mh-e/mh-init.el b/lisp/mh-e/mh-init.el
index 0e19da4fa7d..2297fef6a80 100644
--- a/lisp/mh-e/mh-init.el
+++ b/lisp/mh-e/mh-init.el
@@ -127,13 +127,13 @@ finally GNU mailutils."
((mh-variant-set-variant 'mu-mh)
(message "%s installed as MH variant" mh-variant-in-use))
(t
- (message "No MH variant found on the system!"))))
+ (message "No MH variant found on the system"))))
((member variant valid-list)
(when (not (mh-variant-set-variant variant))
- (message "Warning: %s variant not found. Autodetecting..." variant)
+ (message "Warning: %s variant not found. Autodetecting..." variant)
(mh-variant-set 'autodetect)))
(t
- (message "Unknown variant. Use %s"
+ (message "Unknown variant; use %s"
(mapconcat '(lambda (x) (format "%s" (car x)))
mh-variants " or "))))))
diff --git a/lisp/mh-e/mh-mime.el b/lisp/mh-e/mh-mime.el
index d8102fe6582..f7377d80b2d 100644
--- a/lisp/mh-e/mh-mime.el
+++ b/lisp/mh-e/mh-mime.el
@@ -505,7 +505,7 @@ a prefix argument NOCONFIRM."
".orig")))))
(setq backup-strings (cdr backup-strings)))
(or backup-strings
- (error "Backup file for %s no longer exists!" buffer-file-name))
+ (error "Backup file for %s no longer exists" buffer-file-name))
(or noconfirm
(yes-or-no-p (format "Revert buffer from file %s? "
backup-file))
@@ -585,7 +585,7 @@ MESSAGE number."
mh-user-path (substring folder 1) msg)
"message/rfc822"
description)))
- (t (error "The message number, %s is not a integer!" msg)))))
+ (t (error "The message number, %s, is not a integer" msg)))))
(defvar mh-mml-cryptographic-method-history ())
@@ -633,9 +633,9 @@ IDENTITY is optionally the default-user-id to use."
(let ((valid-methods (list "pgpmime" "pgp" "smime"))
(valid-modes (list "sign" "encrypt" "signencrypt" "none")))
(if (not (member method valid-methods))
- (error "Method \"%s\" is invalid" method))
+ (error "Method %s is invalid" method))
(if (not (member mode valid-modes))
- (error "Mode \"%s\" is invalid" mode))
+ (error "Mode %s is invalid" mode))
(mml-unsecure-message)
(if (not (string= mode "none"))
(save-excursion
@@ -967,7 +967,7 @@ parsed and then displayed."
(mh-mime-display-part handles))
(t (mh-signature-highlight))))
(error
- (message "Please report this error. The error message is:\n %s"
+ (message "Please report this error:\n %s"
(error-message-string err))
(delete-region (point-min) (point-max))
(insert raw-message-data))))))
diff --git a/lisp/mh-e/mh-pick.el b/lisp/mh-e/mh-pick.el
index 8089d3e8ae7..e87e3d11f8d 100644
--- a/lisp/mh-e/mh-pick.el
+++ b/lisp/mh-e/mh-pick.el
@@ -143,7 +143,7 @@ configuration and is used when the search folder is dismissed."
'mh-previous-window-config window-config)
(message "%s" (substitute-command-keys
(concat "Type \\[mh-do-search] to search messages, "
- "\\[mh-help] for help.")))))
+ "\\[mh-help] for help")))))
(defun mh-make-pick-template ()
"Initialize the current buffer with a template for a pick pattern."
@@ -335,7 +335,7 @@ COMPONENT is the component to search."
((eq (car expr) 'not)
`("-lbrace" "-not" ,@(mh-pick-construct-regexp (cadr expr) component)
"-rbrace"))
- (t (error "Unknown operator '%s' seen" (car expr)))))
+ (t (error "Unknown operator %s seen" (car expr)))))
;; All implementations of pick have special options -cc, -date, -from and
;; -subject that allow to search for corresponding components. Any other
diff --git a/lisp/mh-e/mh-seq.el b/lisp/mh-e/mh-seq.el
index 5dab59b270f..53bae76cc07 100644
--- a/lisp/mh-e/mh-seq.el
+++ b/lisp/mh-e/mh-seq.el
@@ -284,7 +284,7 @@ When you want to widen the view to all your messages again, use
mh-show-seq-tool-bar-map))))
(push 'widen mh-view-ops)))
(t
- (error "No messages in sequence \"%s\"" (symbol-name sequence))))))
+ (error "No messages in sequence %s" (symbol-name sequence))))))
;;;###mh-autoload
(defun mh-put-msg-in-seq (range sequence)
@@ -304,7 +304,7 @@ use."
(interactive (list (mh-interactive-range "Add messages from")
(mh-read-seq-default "Add to" nil)))
(unless (mh-valid-seq-p sequence)
- (error "Can't put message in invalid sequence \"%s\"" sequence))
+ (error "Can't put message in invalid sequence %s" sequence))
(let* ((internal-seq-flag (mh-internal-seq sequence))
(original-msgs (mh-seq-msgs (mh-find-seq sequence)))
(folders (list mh-current-folder))
@@ -432,7 +432,7 @@ containing the current message."
(t (intern input))))
(msgs (mh-seq-to-msgs seq)))
(if (and (null msgs) not-empty)
- (error "No messages in sequence \"%s\"" seq))
+ (error "No messages in sequence %s" seq))
seq))
@@ -549,7 +549,7 @@ should be replaced with:
((assoc (intern input) seq-list)
(cdr (assoc (intern input) seq-list)))
((setq msg-list (mh-translate-range folder input)) msg-list)
- (t (error "No messages in range \"%s\"" input)))))
+ (t (error "No messages in range %s" input)))))
;;;###mh-autoload
(defun mh-translate-range (folder expr)
@@ -1176,7 +1176,7 @@ children."
(mh-message-id (mh-container-message kid)))
(let ((kid-message (mh-container-message kid)))
(return (mh-message-subject kid-message)))))
- (error "This can't happen!")))))
+ (error "This can't happen")))))
(defun mh-thread-rewind-pruning ()
"Restore the thread tree to its state before pruning."
diff --git a/lisp/mh-e/mh-utils.el b/lisp/mh-e/mh-utils.el
index 0bfadfbe238..f3205a932a2 100644
--- a/lisp/mh-e/mh-utils.el
+++ b/lisp/mh-e/mh-utils.el
@@ -1582,7 +1582,7 @@ The argument CHANGE is ignored."
(cond
;; Check if we have `convert'
((eq mh-x-image-scaling-function 'ignore)
- (message "The `convert' program is needed to display X-Image-URL")
+ (message "The \"convert\" program is needed to display X-Image-URL")
(mh-x-image-set-download-state cache-filename 'try-again))
;; Scale fetched image
((and (funcall mh-x-image-scaling-function temp-file cache-filename)
@@ -2479,7 +2479,7 @@ used in searching."
(new-file-flag
(error "Folder %s does not exist" folder-name))
((not (file-directory-p (mh-expand-file-name folder-name)))
- (error "\"%s\" is not a directory"
+ (error "%s is not a directory"
(mh-expand-file-name folder-name)))))
folder-name))
@@ -2663,7 +2663,7 @@ Set mark after inserted text."
(set-buffer (get-buffer-create mh-log-buffer))
(mh-truncate-log-buffer)
(insert error-message)))
- (error "%s failed, check %s buffer for error message"
+ (error "%s failed, check buffer %s for error message"
command mh-log-buffer)))
(defun mh-list-to-string (l)
@@ -2684,7 +2684,7 @@ Set mark after inserted text."
((listp (car l))
(setq new-list (nconc (mh-list-to-string-1 (car l))
new-list)))
- (t (error "Bad element in mh-list-to-string: %s" (car l))))
+ (t (error "Bad element in `mh-list-to-string': %s" (car l))))
(setq l (cdr l)))
new-list))