diff --git a/resources/recipes/foreign_policy.recipe b/resources/recipes/foreign_policy.recipe new file mode 100644 index 0000000000..5af40a46a7 --- /dev/null +++ b/resources/recipes/foreign_policy.recipe @@ -0,0 +1,28 @@ +from calibre.web.feeds.news import BasicNewsRecipe + +class AdvancedUserRecipe1278059020(BasicNewsRecipe): + title = u'Foreign Policy' + pubisher = 'http://www.foreignpolicy.com' + category = 'Magazine, USA Foreign Policy' + __author__ = 'rty' + oldest_article = 7 + max_articles_per_feed = 100 + masthead_url = 'http://www.foreignpolicy.com/images/fp_logo.jpg' + feeds = [(u'Feed', u'http://www.foreignpolicy.com/node/feed')] + remove_javascript = True + use_embedded_content = False + no_stylesheets = True + language = 'en' + encoding = 'utf-8' + conversion_options = {'linearize_tables':True} + + def print_version(self, url): + return url + '?print=yes&hidecomments=no&page=full' + + remove_tags = [ + dict(name='div', attrs={'id':'share-box'}), + ] + keep_only_tags = [ + # dict(name='div', attrs={'class':'cxArticleHeader'}), + dict(name='div', attrs={'id':['art-mast','art-body']}), + ] diff --git a/resources/recipes/statesman.recipe b/resources/recipes/statesman.recipe new file mode 100644 index 0000000000..1bbf94fa5b --- /dev/null +++ b/resources/recipes/statesman.recipe @@ -0,0 +1,35 @@ +from calibre.web.feeds.news import BasicNewsRecipe + +class AdvancedUserRecipe1278049615(BasicNewsRecipe): + title = u'Statesman' + pubisher = 'http://www.statesman.com/' + description = 'Austin Texas Daily Newspaper' + category = 'News, Austin, Texas' + __author__ = 'rty' + oldest_article = 3 + + max_articles_per_feed = 100 + + feeds = [(u'News', u'http://www.statesman.com/section-rss.do?source=news&includeSubSections=true'), + (u'Business', u'http://www.statesman.com/section-rss.do?source=business&includeSubSections=true'), + (u'Life', u'http://www.statesman.com/section-rss.do?source=life&includesubsection=true'), + (u'Editorial', u'http://www.statesman.com/section-rss.do?source=opinion&includesubsections=true'), + (u'Sports', u'http://www.statesman.com/section-rss.do?source=sports&includeSubSections=true') + ] + masthead_url = "http://www.statesman.com/images/cmg-logo.gif" + #temp_files = [] + #articles_are_obfuscated = True + + remove_javascript = True + use_embedded_content = False + no_stylesheets = True + language = 'en' + encoding = 'utf-8' + conversion_options = {'linearize_tables':True} + remove_tags = [ + dict(name='div', attrs={'id':'cxArticleOptions'}), + ] + keep_only_tags = [ + dict(name='div', attrs={'class':'cxArticleHeader'}), + dict(name='div', attrs={'id':'cxArticleBodyText'}), + ]