From 9d8e8dd8b93013e84668feab5feb4399f06f4044 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Wed, 15 Apr 2009 12:53:40 -0700 Subject: [PATCH] =?UTF-8?q?New=20recipe=20for=20Hessisch=20Nieders=C3=A4ch?= =?UTF-8?q?sische=20Allgemeine=20by=20Oliver=20neissner?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/calibre/gui2/images/news/hna.png | Bin 0 -> 827 bytes src/calibre/web/feeds/recipes/__init__.py | 2 +- src/calibre/web/feeds/recipes/recipe_hna.py | 40 ++++++++++++++++++++ 3 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 src/calibre/gui2/images/news/hna.png create mode 100644 src/calibre/web/feeds/recipes/recipe_hna.py diff --git a/src/calibre/gui2/images/news/hna.png b/src/calibre/gui2/images/news/hna.png new file mode 100644 index 0000000000000000000000000000000000000000..f4e1135dd560ce57312e174c27a044c6295cf7dc GIT binary patch literal 827 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zK-vS0-A-oPfdtD69Mgd`SU*F|v9*U87?@H#T^vI!PA{G8>mBMS(>{Nu<@0;R_s^d3 zp0)i_Q%103;FgIw(VikAfe9D2UPWKo)-UkHNvUe0P6x*#ahD5=I+zw7nQ}to^V;7< z&*sd`EYy3nZPwWXJT{;I{5;G5ub7j8{arkx9D|ooHCH2pVu6|)i{y&1z-x)djAnBW zMaLX7ix>56@G+2k_<(nj@bS*__ey)pXK%RFS@%t(c*XP`6Bd`fGZ9I_;_g zW6Las@I%^L6}T%ey_HR|_fdMspUjrO$Sm~4UFn0*ick2@PfSQCP21VkmAqzBgukPR z>h$e-3-w};*;Mk_+Ro68-4U)|I9q$i+uPR|YUE{?6r4VNqE&TEQ$cp?iyMMZPB=fg zn*HMO-xq&>d+e7u>Qn0!Z^Q4j#&hAE_JHQC6F42*C!9b0rY0#OAVBBP9i}zs8z+3I zRb{lvvVP#Qm@Vj0i-SaSFqd%KjFP?^PGLtmk_-2>UkIEOHX(P}#qY-!iYw|aNIb}S z!fKt2sEt&7O0410*PQY}b{YpJFOX%?J!!w=!gp!O@SWCtf7utVeNvpRljL9B=2_nt zc3oln=I*`Ln|*w=?asB#dDUC_e|2WT*IyI5Q~A0V*{)w{u9Q|6VRhQo?%cJTd*TAL zSkBbXUU+9?XWK`O)%reXp9?o{GHRw`XBBDL=Y5u=UPb_R9T;)!`@R z?eaPwN;Q2~?mp1`d~>Jc`ICw1b^B6x-SgG_J3AufK#K;eVCIyS%2WJvSTzMVE{VQ* zF)(%Ky`G7O7xM+PrXDnF7FAj~qu@cxXPui9#FQ8vvp4(PRLc1L-P9-bC-X!1Z(rrw zq+EcBPqoA~q9nN}HL)aBHw8#A7#SE?>Kd5n8k&X}8d;edSQ(k>8kk!d7`%`AvjV0e jH$NpatrA0nff-1Hp&3L&kd+J*Py>UftDnm{r-UW|Y2a5F literal 0 HcmV?d00001 diff --git a/src/calibre/web/feeds/recipes/__init__.py b/src/calibre/web/feeds/recipes/__init__.py index c6444ec48e..9e2ef1969d 100644 --- a/src/calibre/web/feeds/recipes/__init__.py +++ b/src/calibre/web/feeds/recipes/__init__.py @@ -39,7 +39,7 @@ recipe_modules = ['recipe_' + r for r in ( 'nacional_cro', '24sata', 'dnevni_avaz', 'glas_srpske', '24sata_rs', 'krstarica', 'krstarica_en', 'tanjug', 'laprensa_ni', 'azstarnet', 'corriere_della_sera_it', 'corriere_della_sera_en', 'msdnmag_en', - 'moneynews', 'der_standard', 'diepresse', 'nzz_ger', + 'moneynews', 'der_standard', 'diepresse', 'nzz_ger', 'hna', )] import re, imp, inspect, time, os diff --git a/src/calibre/web/feeds/recipes/recipe_hna.py b/src/calibre/web/feeds/recipes/recipe_hna.py new file mode 100644 index 0000000000..40193336d1 --- /dev/null +++ b/src/calibre/web/feeds/recipes/recipe_hna.py @@ -0,0 +1,40 @@ +__license__ = 'GPL v3' +__copyright__ = '2008, Kovid Goyal ' + +''' +Fetch Hessisch Niedersächsische Allgemeine. +''' + +from calibre.web.feeds.news import BasicNewsRecipe + + +class hnaDe(BasicNewsRecipe): + + title = 'HNA' + description = 'local news from Hessen/Germany' + __author__ = 'Oliver Niesner' + use_embedded_content = False + language = _('German') + use_embedded_content = False + timefmt = ' [%d %b %Y]' + max_articles_per_feed = 40 + no_stylesheets = True + encoding = 'iso-8859-1' + + remove_tags = [dict(id='topnav'), + dict(id='nav_main'), + dict(id='suchen'), + dict(id=''), + dict(name='span'), + dict(name='ul', attrs={'class':'linklist'}), + dict(name='a', attrs={'href':'#'}), + dict(name='p', attrs={'class':'breadcrumb'}), + dict(name='p', attrs={'class':'h5'})] + #remove_tags_after = [dict(name='div', attrs={'class':'rahmenbreaking'})] + remove_tags_after = [dict(name='a', attrs={'href':'#'})] + + feeds = [ ('hna_soehre', 'http://feeds2.feedburner.com/hna/soehre'), + ('hna_kassel', 'http://feeds2.feedburner.com/hna/kassel') ] + + +