This commit is contained in:
Kovid Goyal 2019-11-07 14:52:14 +05:30
parent fe066ce2d6
commit 481013d23f
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
3 changed files with 7 additions and 4 deletions

View File

@ -1,5 +1,4 @@
# vim:fileencoding=UTF-8:ts=4:sw=4:sta:et:sts=4:fdm=marker:ai # vim:fileencoding=UTF-8:ts=4:sw=4:sta:et:sts=4:fdm=marker:ai
import re
from calibre.web.feeds.news import BasicNewsRecipe from calibre.web.feeds.news import BasicNewsRecipe

View File

@ -16,8 +16,12 @@ class Gameplay_pl(BasicNewsRecipe):
no_stylesheets = True no_stylesheets = True
keep_only_tags = [dict( keep_only_tags = [dict(
name='div', attrs={'class':'news-container'})] name='div', attrs={'class':'news-container'})]
remove_tags = [dict(name='div', attrs={'class': ['galeria', 'noedit center im', 'news_list', 'news_list_autor', 'stop_bot', 'tagi', 'news_tagi', 'social-16']}), dict( remove_tags = [
attrs={'usemap': '#map'}), dict(name='a', attrs={'class': ['pin-it-button', 'twitter-share-button']})] dict(name='div', attrs={'class': [
'galeria', 'noedit center im', 'news_list', 'news_list_autor', 'stop_bot', 'tagi', 'news_tagi', 'social-16']}),
dict(attrs={'usemap': '#map'}),
dict(name='a', attrs={'class': ['pin-it-button', 'twitter-share-button']})
]
feeds = [(u'Wiadomo\u015bci', u'https://gameplay.pl/rss/')] feeds = [(u'Wiadomo\u015bci', u'https://gameplay.pl/rss/')]
def image_url_processor(self, baseurl, url): def image_url_processor(self, baseurl, url):

View File

@ -998,7 +998,7 @@ def opts_and_exts(name, op, exts, cover_opts=('--cover',), opf_opts=(),
extras.append(special_exts_template%(opt, eexts)) extras.append(special_exts_template%(opt, eexts))
extras = '\n'.join(extras) extras = '\n'.join(extras)
return ('_'+fname+'()'+\ return ('_'+fname+'()'+
''' '''
{ {
local cur prev opts local cur prev opts