From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alex Kost Newsgroups: gmane.lisp.guile.user Subject: Re: Very Small Atom Feed Reader Date: Sun, 13 Mar 2016 13:42:57 +0300 Message-ID: <878u1my7ym.fsf@gmail.com> References: <0255377f2892d74fa18c2d534c47bf4d@hypermove.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1457877053 18490 80.91.229.3 (13 Mar 2016 13:50:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 13 Mar 2016 13:50:53 +0000 (UTC) Cc: Guile User To: Amirouche Boubekki Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Sun Mar 13 14:50:48 2016 Return-path: Envelope-to: guile-user@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1af6Pu-00014I-Hg for guile-user@m.gmane.org; Sun, 13 Mar 2016 14:50:46 +0100 Original-Received: from localhost ([::1]:36114 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1af6Pt-0004HE-PR for guile-user@m.gmane.org; Sun, 13 Mar 2016 09:50:45 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60129) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1af3U0-0002Vo-Mv for guile-user@gnu.org; Sun, 13 Mar 2016 06:42:49 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1af3Tt-00081R-Kp for guile-user@gnu.org; Sun, 13 Mar 2016 06:42:48 -0400 Original-Received: from mail-lb0-x232.google.com ([2a00:1450:4010:c04::232]:35478) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1af3Tt-00081H-DG for guile-user@gnu.org; Sun, 13 Mar 2016 06:42:41 -0400 Original-Received: by mail-lb0-x232.google.com with SMTP id bc4so205511907lbc.2 for ; Sun, 13 Mar 2016 03:42:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=YI0VkgK12P41wUT5BJ4uPMibcKvNTQe/3gneXeMcTWk=; b=eAxhR1hADY1W2Yxt8kvEFUoSWY2q8PRmg4GVlpGKghLDgwgD3HM2NSSN3yuK1qStod 2lmAwJ2qQM5YeOD+o4izxu4oglzOPeXf7Yj3mtk8QLxuS08jxJAtoMPXd/qxChw2JL0U VLrKkhjC2aJfcblsVwfGcf7bv2Oz4oLRBAqP0/Z8ArYB8XPhHSe1i1r0nGnSlRm5CMuH 0q5VaiFg9NQRnRyW5jKWnCpYY6MNJkyWtBWyG0iAufS9HLpZglL5mC0tY0iny+xwm7Ur AhWLhwhqObDBHHR+JhyZWyjmUrWSwG8PnYzFWtGftOOyarjEg+bGR8BS6bNG0ybdW3Pb rqsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=YI0VkgK12P41wUT5BJ4uPMibcKvNTQe/3gneXeMcTWk=; b=lr2xFFihFA+nSukbzKsMgfVktV5brRQqryuuJ6w0SQCT7aB0Dyukhff+sXImRuJmTX s4B2Zg4lHb7G7bgd4DcCcdFGC27NAtFIBWXFyo13N/WKaOajKGkEJQgTlVmPI/fYJPXH djomNnEtXCuT56ghG8zRhKkd2M7wx9XMkViEMPLuYbd1OADTA/T6y/tHDcgwbLDYcLdz nvPQPJJEVftmY4wbmrVNwzJd19zLOeKYvbmomQX83vXnoYF0kjmGw/Gl7beJcwn4eF9z iKRP0lhYfktF3oEEQ5RHEwrVnh1ERClEnK8Z4ZVvRK+TqZ/nMqoSWtXGE3Eaf6fm38U/ o/Uw== X-Gm-Message-State: AD7BkJLmau5D6wEyIQVcNm8M00l4mDfZMg1FPHolUZm3DELV8uzFzzU0XzE6DkLv9P4N+w== X-Received: by 10.112.182.42 with SMTP id eb10mr5938965lbc.132.1457865760461; Sun, 13 Mar 2016 03:42:40 -0700 (PDT) Original-Received: from leviafan ([217.107.192.146]) by smtp.gmail.com with ESMTPSA id j205sm2808745lfd.0.2016.03.13.03.42.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 13 Mar 2016 03:42:39 -0700 (PDT) In-Reply-To: <0255377f2892d74fa18c2d534c47bf4d@hypermove.net> (Amirouche Boubekki's message of "Sun, 06 Mar 2016 15:12:02 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:4010:c04::232 X-Mailman-Approved-At: Sun, 13 Mar 2016 09:50:25 -0400 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Original-Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.user:12476 Archived-At: Amirouche Boubekki (2016-03-06 17:12 +0300) wrote: > H=C3=A9llo, Hi there! > I share with you this small *atom* feed reader which works from command > line. Create a ~/.prime.txt file with the address of atom files you want > to follow and then run the script. > > The problem I have is that it fails on wingolog and others but I'm > accepting patches ;) > (use-modules (srfi srfi-9)) > (use-modules (srfi srfi-19)) > (use-modules (srfi srfi-26)) > (use-modules (ice-9 match)) > (use-modules (ice-9 rdelim)) > (use-modules (ice-9 receive)) > (use-modules (sxml xpath)) > (use-modules (sxml simple)) > (use-modules (srfi srfi-1)) > (use-modules (web client)) Why do you use 'use-modules' for every module instead of: (use-modules (srfi srfi-1) (srfi srfi-9) ...) [...] > ;;; sxml procedures > (define (file->sxml filename) > (cdr (xml->sxml (with-input-from-file filename > (lambda () > (read-string)))))) No need in lambda here, just: (with-input-from-file filename read-string) --=20 Alex