From ea124d6afaa06620dfe0ed48e9090a8022c42a09 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 25 Dec 2009 23:48:43 -0700 Subject: [PATCH] New recipes for CNET News, Business Week Magazine and Dilbert --- Changelog.yaml | 22 ++++++++++++-- resources/images/news/bwmagazine.png | Bin 0 -> 446 bytes resources/images/news/cnetnews.png | Bin 0 -> 892 bytes resources/images/news/dilbert.png | Bin 0 -> 657 bytes resources/recipes/bwmagazine.recipe | 38 +++++++++++++++++++++++++ resources/recipes/cnetnews.recipe | 37 ++++++++++++++++++++++++ resources/recipes/dilbert.recipe | 41 +++++++++++++++++++++++++++ 7 files changed, 135 insertions(+), 3 deletions(-) create mode 100644 resources/images/news/bwmagazine.png create mode 100644 resources/images/news/cnetnews.png create mode 100644 resources/images/news/dilbert.png create mode 100644 resources/recipes/bwmagazine.recipe create mode 100644 resources/recipes/cnetnews.recipe create mode 100644 resources/recipes/dilbert.recipe diff --git a/Changelog.yaml b/Changelog.yaml index 9b57868391..5fab5eb3b3 100644 --- a/Changelog.yaml +++ b/Changelog.yaml @@ -4,11 +4,18 @@ # for important features/bug fixes. # Also, each release can have new and improved recipes. -- version: 0.6.29 - date: 2009-12-25 +- version: 0.6.30 + date: 2009-12-26 new features: + - title: "Update graphical toolkit to Qt 4.6 for better integration with Windows 7 and OS X Snow Leopard." + description: > + "The library calibre uses to draw its user interface, Qt, has been updated in all binary builds to + version 4.6. This provides better support for Windows 7 and OS X Snow Leopard,a s well as various + speed ups in the user interface and e-book viewer rendering. Note that calibre will still run with + Qt 4.5" + - title: "Device drivers: Support for device specific icons" - title: "Add menu options to delete specific formats/covers from the library" @@ -23,7 +30,7 @@ - title: "Nook driver: Upload covers when sending to device. Also add Output Profile for the Nook" - - title: "Double clicking on row numbers will now open the book in the viewer" + - title: "Clicking on row numbers in the book list will now open the book in the viewer" tickets: [4266] - title: "Driver for the Boox reader" @@ -61,6 +68,15 @@ new recipes: + - title: Business Week Magazine + author: Darko Mieltic + + - title: CNET News + author: Darko Miletic + + - title: Dilbert + author: Darko Miletic + - title: Le Temps author: Sujata Raman diff --git a/resources/images/news/bwmagazine.png b/resources/images/news/bwmagazine.png new file mode 100644 index 0000000000000000000000000000000000000000..7463884fed14a365f5cb13e72b4418b462287eb9 GIT binary patch literal 446 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=fdzwj^(N7l!{JxM1({$v_d#0*}aI zAngIhZYQ(tK!Rljj_E*J0gT&!&6x{iJoj{Q42d}Wc3P}ZvjR`c_Pr51B)_CROnKSt zJ3Hw|p!^G;pJ@`RT#+Xpap?S;JDb5M_(1J9J{?AT9fy?bMxTEdrpa|xCiA~{I48;A z;Ig~3%yf0xroG|l)TAEi)lV$nHqN*d{y*?b_Qqh<7lGa) zP7EJ3A8Ilhx}~IT-)B|GkvKgks_Q?cS?yRWZ!yx!Y{^(HFeXnn^|9cGA^!PkgHq#jYp$ljr}6k zgk23sldSybZb~g*7ybV=(95bNt`Q|Ei6yC4$wjF^iowXhz*5)HNY}_T#K_pn#Kg+T zSl7VZ%D_OE$tnp&LvDUbW?CgegIS1yft7)Um4O*V!{pPdGl3cyJYD@<);T3K0RW@i Bp+5is literal 0 HcmV?d00001 diff --git a/resources/images/news/cnetnews.png b/resources/images/news/cnetnews.png new file mode 100644 index 0000000000000000000000000000000000000000..9a0dcc8f7fa7645db5f97ef0b5e2978133e05732 GIT binary patch literal 892 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zK-vS0-A-oPfdtD69Mgd`SU*F|v9*U87?_rNx;TbdoKBs5HhW6A$g%qG_pTQj9XoPS zgUd~N@st@t=De* zacN=G@pZC`V(gs?9`1fEy;#%tp}*Ix>$`Wk&56!=&G>S*>#pqU6K6%ir>>}4qV!Kd6U%X$;Qn!IYp}f_bzlv?~~pAUA{rt zJu!*>^=(atyg!Ri&9Y#8@Nc6qb6I?^7PF}Y?}fTwQok29zZPMbvi?zH+gkJgi}qH2 z=kl)+EuDBoKbpJ#(w^-OYu{YzZCk}#v*OXdy$mMe(Li*^OP;yFZHd*A^ux3DuN0N9 z+n3H?wZgID6OW>?VH@oX5I){wfOzj_lxQS|M!^K8!q~{E;65oOVqVR zpkU&$wn7D=tq3fJd+cw3`+^8Y@;2bVf#Zap-8>51olH?)FK#IZ0z`#=1&`8(FG{nf* z$^?ikbPdd{3=Fup)uf?l$jwj5OshoGU~FM!XaLc0!9Hs(Py>UftDnm{r-UW|`oMrT literal 0 HcmV?d00001 diff --git a/resources/images/news/dilbert.png b/resources/images/news/dilbert.png new file mode 100644 index 0000000000000000000000000000000000000000..ffc706c05e4451c9c7175295a91f0c354a682972 GIT binary patch literal 657 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zK-vS0-A-oPfdtD69Mgd`SU*F|v9*U87#MeXx;TbdoSr(#&?7ofq|H8RC1ZQ|ig0De zrbe?TjiySPA?)G{JFX;!Xz-N@z6@ef^!wycAh4@cQ?w+YBv6KBxzEfaD(9EzPPq}V zxaE^cT1F64*o4;$?0n77FtJsZ#8vfh&=Jyjr2 z-#T#aMo!-40Y3YD4rq$RG&=68RgKYSo}ThhM1+0+_T&_sf18pT*r(2AlGV@S;$D6= zxt#Nlw&b)W*$cBaO09CRspRQ8d?@wv9sdUxH!p87|9;}h`IB$eGe7*0l>hRE?pqfbVPvVf^vb>c6P@?Yon}1!t-><*%DaE(OyvK&<%+$^o}H(z z-Lm=IefrFq)_}WB%_WEGI(Pnka&yTg!>Wzrz46K1A=@y3~w6*nKX zdPVds=}P(<)^&K!xv&SnzllxUaq#AOll0?}n?F=F&0XR5==Hq6;zmD;U@y?L1(#sR~xdNk9wZt`|BqgyV)hf9t6-Y4{ z85mgV8XD;unT8k{TbUSJ8JOrAm|Gbbc*ID&K+%w!pOTqYiKfBG(8|aFq9Iv(rVCI5 NgQu&X%Q~loCIDSa4Y~jT literal 0 HcmV?d00001 diff --git a/resources/recipes/bwmagazine.recipe b/resources/recipes/bwmagazine.recipe new file mode 100644 index 0000000000..e8c0908fef --- /dev/null +++ b/resources/recipes/bwmagazine.recipe @@ -0,0 +1,38 @@ + +__license__ = 'GPL v3' +__copyright__ = '2009, Darko Miletic ' +''' +http://www.businessweek.com/magazine/news/articles/business_news.htm +''' + +from calibre.web.feeds.news import BasicNewsRecipe + +class BWmagazine(BasicNewsRecipe): + title = 'BusinessWeek Magazine' + __author__ = 'Darko Miletic' + description = 'Stay up to date with BusinessWeek magazine articles. Read news on international business, personal finances & the economy in the BusinessWeek online magazine.' + publisher = 'BusinessWeek' + category = 'news, finances, politics, USA' + oldest_article = 50 + max_articles_per_feed = 100 + no_stylesheets = True + encoding = 'utf-8' + use_embedded_content = False + language = 'en' + cover_url = 'http://images.businessweek.com/mz/covers/current_120x160.jpg' + + conversion_options = { + 'comment' : description + , 'tags' : category + , 'publisher' : publisher + , 'language' : language + } + + keep_only_tags = dict(name='div', attrs={'id':'storyBody'}) + + feeds = [(u'Articles', u'http://rss.businessweek.com/bw_rss/magazine')] + + def print_version(self, url): + rurl = url.rpartition('?')[0] + return rurl.replace('.com/magazine/','.com/print/magazine/') + diff --git a/resources/recipes/cnetnews.recipe b/resources/recipes/cnetnews.recipe new file mode 100644 index 0000000000..bfd4879dea --- /dev/null +++ b/resources/recipes/cnetnews.recipe @@ -0,0 +1,37 @@ + +__license__ = 'GPL v3' +__copyright__ = '2009, Darko Miletic ' +''' +news.cnet.com +''' + +from calibre.web.feeds.news import BasicNewsRecipe + +class CnetNews(BasicNewsRecipe): + title = 'CNET News' + __author__ = 'Darko Miletic' + description = 'Tech news and business reports by CNET News. Focused on information technology, core topics include computers, hardware, software, networking, and Internet media.' + publisher = 'CNET' + category = 'news, IT, USA' + oldest_article = 2 + max_articles_per_feed = 100 + no_stylesheets = True + encoding = 'cp1252' + use_embedded_content = False + language = 'en' + + conversion_options = { + 'comment' : description + , 'tags' : category + , 'publisher' : publisher + , 'language' : language + } + + remove_tags = [ + dict(name='div', attrs={'id':'tweetmemeAndFacebook'}) + ,dict(name='ul', attrs={'class':'contentTools'}) + ] + keep_only_tags = dict(name='div', attrs={'class':'txtWrap'}) + + feeds = [(u'News', u'http://news.cnet.com/2547-1_3-0-20.xml')] + diff --git a/resources/recipes/dilbert.recipe b/resources/recipes/dilbert.recipe new file mode 100644 index 0000000000..ddca52b40a --- /dev/null +++ b/resources/recipes/dilbert.recipe @@ -0,0 +1,41 @@ +__license__ = 'GPL v3' +__copyright__ = '2009, Darko Miletic ' +''' +http://www.dilbert.com +''' + +from calibre.web.feeds.recipes import BasicNewsRecipe + +class DosisDiarias(BasicNewsRecipe): + title = 'Dilbert' + __author__ = 'Darko Miletic' + description = 'Dilbert' + oldest_article = 5 + max_articles_per_feed = 100 + no_stylesheets = True + use_embedded_content = True + encoding = 'utf-8' + publisher = 'UNITED FEATURE SYNDICATE, INC.' + category = 'comic' + language = 'en' + + conversion_options = { + 'comments' : description + ,'tags' : category + ,'language' : language + ,'publisher' : publisher + } + + feeds = [(u'Dilbert', u'http://feeds.dilbert.com/DilbertDailyStrip' )] + + def get_article_url(self, article): + return article.get('feedburner_origlink', None) + + def preprocess_html(self, soup): + for tag in soup.findAll(name='a'): + if tag['href'].find('http://feedads') >= 0: + tag.extract() + return soup + + +