Spectator Australia by James Cridland
This commit is contained in:
Kovid Goyal 2020-02-25 19:20:19 +05:30
commit 2aa41c859b
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
5 changed files with 37 additions and 27 deletions

View File

@ -1,26 +0,0 @@
from calibre.web.feeds.news import BasicNewsRecipe
class AdvancedUserRecipe1336986047(BasicNewsRecipe):
title = u'Ads of the World'
oldest_article = 7
max_articles_per_feed = 100
auto_cleanup = False
description = 'The best international advertising campaigns'
language = 'en'
__author__ = 'faber1971'
no_stylesheets = True
keep_only_tags = [
dict(name='div', attrs={'id': 'primary'})
]
remove_tags = [
dict(name='ul', attrs={'class': 'links inline'}), dict(name='div', attrs={'class': 'form-item'}), dict(
name='div', attrs={'id': ['options', 'comments']}), dict(name='ul', attrs={'id': 'nodePager'})
]
reverse_article_order = True
masthead_url = 'http://bigcatgroup.co.uk/files/2011/01/05-ads-of-the-world.png'
feeds = [
(u'Ads of the world', u'http://feeds.feedburner.com/adsoftheworld-latest')]

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

View File

@ -17,7 +17,7 @@ class AListApart (BasicNewsRecipe):
oldest_article = 120 oldest_article = 120
remove_empty_feeds = True remove_empty_feeds = True
encoding = 'utf8' encoding = 'utf8'
cover_url = u'http://alistapart.com/pix/alalogo.gif' cover_url = u'https://alistapart.com/wp-content/uploads/2019/03/cropped-icon_navigation-laurel-512.jpg'
def get_extra_css(self): def get_extra_css(self):
if not self.extra_css: if not self.extra_css:

View File

@ -0,0 +1,36 @@
__license__ = 'GPL v3'
__copyright__ = '2011, Pat Stapleton <pat.stapleton at gmail.com>'
'''
https://www.spectator.com.au/
'''
import re
from calibre.web.feeds.recipes import BasicNewsRecipe
class SpectatorAU(BasicNewsRecipe):
title = 'Spectator Australia'
__author__ = 'Pat Stapleton, Dean Cording, James Cridland'
description = 'Spectator Australia is an Australian edition of The Spectator, first published in the UK in July 1828.'
masthead_url = 'https://www.spectator.com.au/content/themes/spectator-australia/assets/images/spec-aus-logo.png'
cover_url = 'https://spectator.imgix.net/content/uploads/2015/10/Spectator-Australia-Logo.jpg'
oldest_article = 7
handle_gzip = True
no_stylesheets = True
use_embedded_content = False
scale_news_images_to_device = True
encoding = 'utf8'
publisher = 'Spectator Australia'
category = 'Australia,News'
language = 'en_AU'
publication_type = 'newspaper'
extra_css = '.article-header__author{margin-bottom:20px;}'
conversion_options = {
'comments': description, 'tags': category, 'language': language, 'publisher': publisher, 'linearize_tables': False
}
keep_only_tags = [dict(attrs={'class': ['article']})]
remove_tags = [dict(attrs={'class': ['big-author','article-header__category','margin-menu','related-stories','disqus_thread','middle-promo','show-comments','article-tags']}), dict(name=['h4','hr'])]
remove_attributes = ['width', 'height']
feeds = [
('Spectator Australia', 'https://www.spectator.com.au/feed/'),
]