;;; gnus-sync.el --- synchronization facility for Gnus
-;; Copyright (C) 2010-2012 Free Software Foundation, Inc.
+;; Copyright (C) 2010-2015 Free Software Foundation, Inc.
;; Author: Ted Zlatanov <tzz@lifelogs.com>
;; Keywords: news synchronization nntp nnrss
(require 'gmm-utils)
(defvar gnus-topic-alist) ;; gnus-group.el
-(eval-when-compile
- (autoload 'gnus-group-topic "gnus-topic")
- (autoload 'gnus-topic-create-topic "gnus-topic" nil t)
- (autoload 'gnus-topic-enter-dribble "gnus-topic"))
+(autoload 'gnus-group-topic "gnus-topic")
(defgroup gnus-sync nil
"The Gnus synchronization facility."
(defvar gnus-sync-newsrc-loader nil
"Carrier for newsrc data")
+(defcustom gnus-sync-file-encrypt-to nil
+ "If non-nil, set `epa-file-encrypt-to' from this for encrypting the Sync file."
+ :version "24.4"
+ :type '(choice string (repeat string))
+ :group 'gnus-sync)
+
(defcustom gnus-sync-lesync-name (system-name)
"The LeSync name for this machine."
:group 'gnus-sync
loc name gnus-sync-lesync-name (or sources "")))
nil)))
+(declare-function gnus-topic-create-topic "gnus-topic"
+ (topic parent &optional previous full-topic))
+(declare-function gnus-topic-enter-dribble "gnus-topic" ())
+
(defun gnus-sync-lesync-install-group-entry (name)
(let* ((master (assoc name gnus-newsrc-alist))
(old-topic-name (gnus-group-topic name))
(progn
(let ((coding-system-for-write gnus-ding-file-coding-system)
(standard-output (current-buffer)))
+ (when gnus-sync-file-encrypt-to
+ (set (make-local-variable 'epa-file-encrypt-to)
+ gnus-sync-file-encrypt-to))
(princ (format ";; -*- mode:emacs-lisp; coding: %s; -*-\n"
gnus-ding-file-coding-system))
(princ ";; Gnus sync data v. 0.0.1\n")