summaryrefslogtreecommitdiff
path: root/lisp/gnus/nnrss.el
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>2006-01-17 02:39:39 +0000
committerMiles Bader <miles@gnu.org>2006-01-17 02:39:39 +0000
commit89334b9f041ec2566c31781f43f0dcee4ca0d62c (patch)
treef9d1d01dd34883e1086ce96b4e7d04b166a2286f /lisp/gnus/nnrss.el
parent2ecea044110f0e51a2989bfbad8261b4f67b29a1 (diff)
downloademacs-89334b9f041ec2566c31781f43f0dcee4ca0d62c.tar.gz
Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-702
Merge from gnus--rel--5.10 Patches applied: * gnus--rel--5.10 (patch 185-186) - Merge from emacs--cvs-trunk--0 - Update from CVS 2006-01-16 Katsumi Yamaoka <yamaoka@jpl.org> * lisp/gnus/nnrss.el: Update copyright. (nnrss-opml-import): Query whether to subscribe to each entry. * lisp/gnus/gnus-art.el: * lisp/gnus/gnus-cus.el: * lisp/gnus/gnus-group.el: * lisp/gnus/gnus-start.el: * lisp/gnus/gnus-sum.el: * lisp/gnus/mm-uu.el: * lisp/gnus/mm-view.el: Update copyright. 2006-01-16 Reiner Steib <Reiner.Steib@gmx.de> * lisp/gnus/message.el (message-info): New function. (message-mode-menu): Add it. Update copyright. * lisp/gnus/ChangeLog: Fix and update copyright. 2006-01-16 Katsumi Yamaoka <yamaoka@jpl.org> * man/gnus.texi: Update copyright.
Diffstat (limited to 'lisp/gnus/nnrss.el')
-rw-r--r--lisp/gnus/nnrss.el32
1 files changed, 24 insertions, 8 deletions
diff --git a/lisp/gnus/nnrss.el b/lisp/gnus/nnrss.el
index 18a54d05d0d..318560179f5 100644
--- a/lisp/gnus/nnrss.el
+++ b/lisp/gnus/nnrss.el
@@ -1,6 +1,7 @@
;;; nnrss.el --- interfacing with RSS
-;; Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2002, 2003, 2004, 2005,
+;; 2006 Free Software Foundation, Inc.
;; Author: Shenghuo Zhu <zsh@cs.rochester.edu>
;; Keywords: RSS
@@ -755,14 +756,29 @@ which RSS 2.0 allows."
"OPML subscriptions import.
Read the file and attempt to subscribe to each Feed in the file."
(interactive "fImport file: ")
- (mapcar
- (lambda (node) (gnus-group-make-rss-group
- (cdr (assq 'xmlUrl (cadr node)))))
+ (mapc
+ (lambda (node)
+ (let ((xmlurl (cdr (assq 'xmlUrl (cadr node)))))
+ (when (and xmlurl
+ (not (string-match "\\`[\t ]*\\'" xmlurl))
+ (prog1
+ (y-or-n-p (format "Subscribe to %s " xmlurl))
+ (message "")))
+ (condition-case err
+ (progn
+ (gnus-group-make-rss-group xmlurl)
+ (forward-line 1))
+ (error
+ (message
+ "Failed to subscribe to %s (%s); type any key to continue: "
+ xmlurl
+ (error-message-string err))
+ (let ((echo-keystrokes 0))
+ (read-char)))))))
(nnrss-find-el 'outline
- (progn
- (find-file opml-file)
- (xml-parse-region (point-min)
- (point-max))))))
+ (mm-with-multibyte-buffer
+ (insert-file-contents opml-file)
+ (xml-parse-region (point-min) (point-max))))))
(defun nnrss-opml-export ()
"OPML subscription export.