mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
pep8
This commit is contained in:
parent
82eed9cad3
commit
961ef505d1
@ -92,7 +92,7 @@ class HNWithCommentsLink(BasicNewsRecipe):
|
|||||||
return u'<html><title>' + title + u'</title><body>' + body + '</body></html>'
|
return u'<html><title>' + title + u'</title><body>' + body + '</body></html>'
|
||||||
|
|
||||||
def parse_feeds(self):
|
def parse_feeds(self):
|
||||||
a = super(HNWithCommentsLinkAlt, self).parse_feeds()
|
a = super().parse_feeds()
|
||||||
self.hn_articles = a[0].articles
|
self.hn_articles = a[0].articles
|
||||||
return a
|
return a
|
||||||
|
|
||||||
@ -114,11 +114,6 @@ class HNWithCommentsLink(BasicNewsRecipe):
|
|||||||
else:
|
else:
|
||||||
content = self.get_readable_content(url)
|
content = self.get_readable_content(url)
|
||||||
|
|
||||||
article = 0
|
|
||||||
for a in self.hn_articles:
|
|
||||||
if a.url == url:
|
|
||||||
article = a
|
|
||||||
|
|
||||||
# content = re.sub(r'</body>\s*</html>\s*$', '', content) + \
|
# content = re.sub(r'</body>\s*</html>\s*$', '', content) + \
|
||||||
# article.summary + '</body></html>'
|
# article.summary + '</body></html>'
|
||||||
|
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
|
|
||||||
from calibre.utils.date import parse_date
|
from calibre.utils.date import parse_date
|
||||||
from calibre.web.feeds.news import BasicNewsRecipe, classes
|
from calibre.web.feeds.news import BasicNewsRecipe, classes
|
||||||
|
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
# vim:fileencoding=utf-8
|
# vim:fileencoding=utf-8
|
||||||
from calibre.web.feeds.news import BasicNewsRecipe
|
from calibre.web.feeds.news import BasicNewsRecipe
|
||||||
|
|
||||||
|
|
||||||
class SalzburgerNachrichten(BasicNewsRecipe):
|
class SalzburgerNachrichten(BasicNewsRecipe):
|
||||||
title = 'Salzburger Nachrichten'
|
title = 'Salzburger Nachrichten'
|
||||||
__author__ = 'İlker Melik Sıtkı'
|
__author__ = 'İlker Melik Sıtkı'
|
||||||
@ -56,4 +57,4 @@ class SalzburgerNachrichten(BasicNewsRecipe):
|
|||||||
('Briefe an die SN', 'https://www.sn.at/leserforum/xml/rss'),
|
('Briefe an die SN', 'https://www.sn.at/leserforum/xml/rss'),
|
||||||
('Veranstaltungen', 'https://www.sn.at/veranstaltungen/xml/rss'),
|
('Veranstaltungen', 'https://www.sn.at/veranstaltungen/xml/rss'),
|
||||||
('Klimawandel', 'https://www.sn.at/panorama/klimawandel/xml/rss')
|
('Klimawandel', 'https://www.sn.at/panorama/klimawandel/xml/rss')
|
||||||
]
|
]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user