diff options
Diffstat (limited to 'lisp/gnus/gnus-cloud.el')
-rw-r--r-- | lisp/gnus/gnus-cloud.el | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lisp/gnus/gnus-cloud.el b/lisp/gnus/gnus-cloud.el index d5970f31265..1aa8e71ae1e 100644 --- a/lisp/gnus/gnus-cloud.el +++ b/lisp/gnus/gnus-cloud.el @@ -28,7 +28,6 @@ ;;; Code: -(eval-when-compile (require 'cl)) (require 'parse-time) (require 'nnimap) @@ -80,7 +79,7 @@ against the basename of files in said directory." (defcustom gnus-cloud-method nil "The IMAP select method used to store the cloud data. -See also `gnus-server-toggle-cloud-method-server' for an +See also `gnus-server-set-cloud-method-server' for an easy interactive way to set this from the Server buffer." :group 'gnus-cloud :type '(radio (const :tag "Not set" nil) @@ -229,7 +228,7 @@ easy interactive way to set this from the Server buffer." Use old data if FORCE-OLDER is not nil." (let* ((contents (plist-get elem :contents)) (date (or (plist-get elem :timestamp) "0")) - (now (gnus-cloud-timestamp (current-time))) + (now (gnus-cloud-timestamp nil)) (newer (string-lessp date now)) (group-info (gnus-get-info group))) (if (and contents @@ -340,7 +339,8 @@ Use old data if FORCE-OLDER is not nil." (format-time-string "%FT%T%z" time)) (defun gnus-cloud-file-new-p (file full) - (let ((timestamp (gnus-cloud-timestamp (nth 5 (file-attributes file)))) + (let ((timestamp (gnus-cloud-timestamp (file-attribute-modification-time + (file-attributes file)))) (old (cadr (assoc file gnus-cloud-file-timestamps)))) (when (or full (null old) @@ -368,6 +368,8 @@ Use old data if FORCE-OLDER is not nil." (interactive) (gnus-cloud-upload-data t)) +(autoload 'gnus-group-refresh-group "gnus-group") + (defun gnus-cloud-upload-data (&optional full) "Upload data (newsrc and files) to the Gnus Cloud. When FULL is t, upload everything, not just a difference from the last full." @@ -498,7 +500,7 @@ Otherwise, returns the Gnus Cloud data chunks." (gnus-method-to-server (gnus-find-method-for-group (gnus-info-group info)))) - (push `(:type :newsrc-data :name ,(gnus-info-group info) :contents ,info :timestamp ,(gnus-cloud-timestamp (current-time))) + (push `(:type :newsrc-data :name ,(gnus-info-group info) :contents ,info :timestamp ,(gnus-cloud-timestamp nil)) infos))) infos)) |