Prompt to save gnus-cloud-method.
Since `gnus-cloud-method' is a defcustom, when it's set, we should prompt the user to save it, so the customization is not lost on restart. * gnus-srvr.el (gnus-server-toggle-cloud-method-server): Prompt to save the customization of `gnus-cloud-method'.
This commit is contained in:
parent
773778e1c0
commit
ec359399a4
1 changed files with 6 additions and 1 deletions
|
@ -1156,7 +1156,12 @@ Requesting compaction of %s... (this may take a long time)"
|
|||
(unless (gnus-cloud-host-acceptable-method-p server)
|
||||
(error "The server under point can't host the Emacs Cloud"))
|
||||
|
||||
(custom-set-variables '(gnus-cloud-method server))
|
||||
(when (not (string-equal gnus-cloud-method server))
|
||||
(custom-set-variables '(gnus-cloud-method server))
|
||||
;; Note we can't use `Custom-save' here.
|
||||
(when (gnus-yes-or-no-p
|
||||
(format "The new cloud host server is %S now. Save it? " server))
|
||||
(customize-save-variable 'gnus-cloud-method server)))
|
||||
(when (gnus-yes-or-no-p (format "Upload Cloud data to %S now? " server))
|
||||
(gnus-message 1 "Uploading all data to Emacs Cloud server %S" server)
|
||||
(gnus-cloud-upload-data t))))
|
||||
|
|
Loading…
Add table
Reference in a new issue