From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/59467 Path: main.gmane.org!not-for-mail From: Katsumi Yamaoka Newsgroups: gmane.emacs.gnus.general Subject: Re: improving nnrss.el Date: Wed, 22 Dec 2004 20:25:14 +0900 Organization: Emacsen advocacy group Message-ID: References: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: sea.gmane.org 1103715051 805 80.91.229.6 (22 Dec 2004 11:30:51 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 22 Dec 2004 11:30:51 +0000 (UTC) Cc: Tsuyoshi AKIHO Original-X-From: ding-owner+M8007@lists.math.uh.edu Wed Dec 22 12:30:45 2004 Return-path: Original-Received: from malifon.math.uh.edu ([129.7.128.13] ident=mail) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1Ch4hX-00023q-00 for ; Wed, 22 Dec 2004 12:30:44 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu ident=lists) by malifon.math.uh.edu with smtp (Exim 3.20 #1) id 1Ch4cf-0000mf-00; Wed, 22 Dec 2004 05:25:41 -0600 Original-Received: from util2.math.uh.edu ([129.7.128.23]) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 1Ch4cU-0000mX-00 for ding@lists.math.uh.edu; Wed, 22 Dec 2004 05:25:30 -0600 Original-Received: from quimby.gnus.org ([80.91.224.244]) by util2.math.uh.edu with esmtp (Exim 4.30) id 1Ch4cP-0003MJ-1S for ding@lists.math.uh.edu; Wed, 22 Dec 2004 05:25:25 -0600 Original-Received: from washington.hostforweb.net ([69.61.11.2]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1Ch4cN-00088W-00 for ; Wed, 22 Dec 2004 12:25:23 +0100 Original-Received: from localhost ([127.0.0.1]) by washington.hostforweb.net with esmtpa (Exim 4.43) id 1Ch4cM-0003zx-WB; Wed, 22 Dec 2004 06:25:23 -0500 Original-To: ding@gnus.org X-Face: #kKnN,xUnmKia.'[pp`;Omh}odZK)?7wQSl"4o04=EixTF+V[""w~iNbM9ZL+.b*_CxUmFk B#Fu[*?MZZH@IkN:!"\w%I_zt>[$nm7nQosZ<3eu;B:$Q_:p!',P.c0-_Cy[dz4oIpw0ESA^D*1Lw= L&i*6&( User-Agent: Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux) Cancel-Lock: sha1:gek1HoXenzkRyV/x0XWCNkuXFEk= X-Hashcash: 1:20:041222:ding@gnus.org::xcDP+n9aLAL4qr8x:00004grg X-Hashcash: 1:20:041222:akiho@kawachi.zaq.ne.jp::Gk4QsOHoD/VXNnap:000000000000000000000000000000000000007J6e X-Antivirus-Scanner: Clean mail though you should still use an Antivirus X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - washington.hostforweb.net X-AntiAbuse: Original Domain - gnus.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - jpl.org X-Source: X-Source-Args: X-Source-Dir: Precedence: bulk Original-Sender: ding-owner@lists.math.uh.edu Xref: main.gmane.org gmane.emacs.gnus.general:59467 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:59467 --=-=-= >>>>>> In Katsumi Yamaoka wrote: >> I and Tsuyoshi AKIHO are now planning to make nnrss.el support >> multilingual text. > ftp://ftp.jpl.org/pub/tmp/nnrss-patch-20041214.gz > or http://www.jpl.org/ftp/pub/tmp/nnrss-patch-20041214.gz The new patch is here: ftp://ftp.jpl.org/pub/tmp/nnrss-patch-20041221.gz or http://www.jpl.org/ftp/pub/tmp/nnrss-patch-20041221.gz To use this patch, you need to use the latest Gnus CVS. I and Tsuyoshi AKIHO will install it into the Gnus trunk in the near feature after he finished the paper work to FSF. The new nnrss.el supports multilingual text and non-ASCII group names. You who are already subscribing to rss groups will need to do some tedious tasks before using the new nnrss.el. I'm sorry for that but it will give you a real advantage. Please note, you won't get a good result if your Emacs doesn't support the `utf-8' coding system. If you are an Emacs user and don't mind the past articles may break a little, you have nothing to do except for removing of the `charset' group parameter. 1. Remove the `charset' group parameter for the rss groups if you've set them. It was a possible workaround in order to decode non-ASCII articles, but it is no longer necessary. 2. You may be able to continue to read past articles using the new nnrss.el, although articles which have broken from the first cannot be helped (it likely occurred because of the old nnrss.el). To attempt to do that, read each rss file as binary, decode the contents using the proper coding system (which was used as the `charset' group parameter, maybe), and save it using the coding system which is specified to the `nnrss-file-coding-system' variable (see below). I made a simple command for doing that. It is attached at the end of this message. OTOH, removing all existing rss groups, removing all files under the ~/News/rss/ directory, restarting Gnus and creating again those groups is a good idea. ;-) 3. If you are an XEmacs user and want to use non-ASCII group names, you have to specify the value for the `nnmail-pathname-coding-system' variable. It is used to encode and decode local rss filenames which will contain non-ASCII group names. The value should be the coding system which is used as your computer's default. For example: (setq nnmail-pathname-coding-system 'iso-8859-1) Although Emacs users don't have to bother to specify it since Emacs should set the `default-file-name-coding-system' variable properly, you can override it in the same way. 4. If you are using both Emacs and XEmacs-MULE, you have to specify the value for the `nnrss-file-coding-system' variable properly. It is used to encode text contents which are saved in local rss files. The default value is `emacs-mule' in Emacs or is `escape-quoted' in XEmacs-MULE, those are incompatible. The possible values include `iso-2022-7bit', `utf-8', `ctext', etc. For example: (setq nnrss-file-coding-system 'iso-2022-7bit) OT: nnshimbun.el contained in the emacs-w3m package is also useful for reading news sites in the world. There are modules for BBC News, Heise, Laut, N24, Rediff, Spiegel, The Register, Welt, Zeit, etc. --=-=-= Content-Type: application/emacs-lisp Content-Disposition: inline (defun nnrss-fixup-file (file csr csw) (interactive (progn (defvar nnrss-fixup-dir "~/News/rss/") (defvar nnrss-fixup-csr default-buffer-file-coding-system) (defvar nnrss-fixup-csw (if (featurep 'xemacs) 'escape-quoted 'emacs-mule)) (list (read-file-name "RSS file: " nnrss-fixup-dir) (read-coding-system (format "Coding system for read (default %s): " nnrss-fixup-csr) nnrss-fixup-csr) (read-coding-system (format "Coding system for write (default %s): " nnrss-fixup-csw) nnrss-fixup-csw)))) (if (and (not (string= file "")) (file-exists-p file) (not (file-directory-p file))) (setq nnrss-fixup-dir (file-name-directory file)) (error "No such file: %s" file)) (if (and csr (if (featurep 'xemacs) (get-coding-system csr) (coding-system-p csr))) (setq nnrss-fixup-csr csr) (error "No such coding system: %s" csr)) (if (and csw (if (featurep 'xemacs) (get-coding-system csw) (coding-system-p csw))) (setq nnrss-fixup-csw csw) (error "No such coding system: %s" csw)) (let ((buffer (get-buffer-create "*nnrss-fixup-file*")) (coding-system-for-read 'binary) (coding-system-for-write csw)) (save-excursion (set-buffer buffer) (erase-buffer) (or (featurep 'xemacs) (set-buffer-multibyte nil)) (insert-file-contents file) (decode-coding-region (point-min) (point-max) csr) (or (featurep 'xemacs) (set-buffer-multibyte t)) (write-region (point-min) (point-max) file)) (kill-buffer buffer))) --=-=-=--