Prereq: 11.0 =================================================================== RCS file: RCS/gnus-start.el,v retrieving revision 11.0 retrieving revision 11.0.1.1 diff -ubw -r11.0 -r11.0.1.1 --- 11.0 1997/09/30 14:33:41 +++ 11.0.1.1 1997/09/30 14:48:55 @@ -34,6 +34,11 @@ (require 'message) (eval-when-compile (require 'cl)) + +(defvar gnus-startup-file-compress-extension "" + "If you want to use compressed .newsrc.eld.gz; set this to \".gz\".") + + (defcustom gnus-startup-file (nnheader-concat gnus-home-directory ".newsrc") "Your `.newsrc' file. `.newsrc-SERVER' will be used instead if that exists." @@ -1075,7 +1080,11 @@ (if (or (> (length gnus-newsrc-alist) 1) (file-exists-p gnus-startup-file) (file-exists-p (concat gnus-startup-file ".el")) - (file-exists-p (concat gnus-startup-file ".eld"))) + (file-exists-p (concat gnus-startup-file ".eld")) + (file-exists-p (concat gnus-startup-file + ".eld" + gnus-startup-file-compress-extension)) + ) nil (gnus-message 6 "First time user; subscribing you to default groups") (unless (gnus-read-active-file-p) @@ -1827,8 +1836,12 @@ (when (and (file-exists-p gnus-current-startup-file) (or force (and (file-newer-than-file-p newsrc-file quick-file) - (file-newer-than-file-p newsrc-file - (concat quick-file "d"))) + (file-newer-than-file-p + newsrc-file + (concat + quick-file "d" + gnus-startup-file-compress-extension + ))) (not gnus-newsrc-alist))) ;; We read the .newsrc file. Note that if there if a ;; .newsrc.eld file exists, it has already been read, and @@ -1875,7 +1888,7 @@ (gnus-uncompress-range ticked))))))))) (defun gnus-read-newsrc-el-file (file) - (let ((ding-file (concat file "d"))) + (let ((ding-file (concat file "d" gnus-startup-file-compress-extension))) ;; We always, always read the .eld file. (gnus-message 5 "Reading %s..." ding-file) (let (gnus-newsrc-assoc) @@ -1955,10 +1968,19 @@ "Make server dependent file name by catenating FILE and server host name." (let* ((file (expand-file-name file nil)) (real-file (concat file "-" (nth 1 gnus-select-method)))) - (if (or (file-exists-p real-file) + (cond + ((file-exists-p (concat real-file ".el" + gnus-startup-file-compress-extension)) + (concat real-file ".el" gnus-startup-file-compress-extension)) + ((file-exists-p (concat file gnus-startup-file-compress-extension)) + (concat file gnus-startup-file-compress-extension)) + ((or (file-exists-p real-file) (file-exists-p (concat real-file ".el")) (file-exists-p (concat real-file ".eld"))) - real-file file))) + real-file) + (t + file + )))) (defun gnus-newsrc-to-gnus-format () (setq gnus-newsrc-options "") @@ -2232,7 +2254,9 @@ (make-local-variable 'version-control) (setq version-control 'never) (setq buffer-file-name - (concat gnus-current-startup-file ".eld")) + (concat gnus-current-startup-file ".eld" + gnus-startup-file-compress-extension + )) (setq default-directory (file-name-directory buffer-file-name)) (gnus-add-current-to-buffer-list) (buffer-disable-undo (current-buffer)) @@ -2284,7 +2308,7 @@ (let ((list gnus-killed-list) olist) (while list - (when (string-match gnus-save-killed-list) + (when (string-match gnus-save-killed-list (car list)) (push (car list) olist)) (pop list)) (nreverse olist)))