summaryrefslogtreecommitdiff
path: root/lisp/gnus/gnus-mh.el
diff options
context:
space:
mode:
authorMike Kupfer <m.kupfer@acm.org>2016-11-21 06:10:13 +0000
committerKatsumi Yamaoka <yamaoka@jpl.org>2016-11-21 06:10:13 +0000
commitf332833e21a32709c4c12f794384b5ef6a719735 (patch)
treeb7f05192c6ba758de8737c29abd7c64245676faa /lisp/gnus/gnus-mh.el
parentcdd056519da9ef058e28b5f198357af52228e9b6 (diff)
downloademacs-f332833e21a32709c4c12f794384b5ef6a719735.tar.gz
Add a variable to pass additional options to rcvstore
* lisp/gnus/gnus-mh.el (gnus-rcvstore-options): New variable. (gnus-summary-save-in-folder): Include gnus-rcvstore-options in the arguments that are passed to rcvstore. cf. <nntp://news.gmane.org/gmane.emacs.gnus.general/87263> and followups, i.e., ding mailing list.
Diffstat (limited to 'lisp/gnus/gnus-mh.el')
-rw-r--r--lisp/gnus/gnus-mh.el15
1 files changed, 13 insertions, 2 deletions
diff --git a/lisp/gnus/gnus-mh.el b/lisp/gnus/gnus-mh.el
index f01811b1ac6..84c90be3235 100644
--- a/lisp/gnus/gnus-mh.el
+++ b/lisp/gnus/gnus-mh.el
@@ -40,6 +40,13 @@
(defvar mh-lib-progs)
+(defcustom gnus-rcvstore-options nil
+ "Options that are passed to rcvstore, or nil.
+These are used when saving articles to an MH folder."
+ :version "26.1"
+ :group 'gnus-article
+ :type '(repeat string))
+
(defun gnus-summary-save-article-folder (&optional arg)
"Append the current article to an mh folder.
If N is a positive number, save the N next articles.
@@ -77,8 +84,12 @@ Optional argument FOLDER specifies folder name."
(save-restriction
(widen)
(unwind-protect
- (call-process-region
- (point-min) (point-max) "rcvstore" nil errbuf nil folder)
+ (apply
+ 'call-process-region
+ (append
+ (list (point-min) (point-max) "rcvstore" nil errbuf nil
+ folder)
+ gnus-rcvstore-options))
(set-buffer errbuf)
(if (zerop (buffer-size))
(message "Article saved in folder: %s" folder)