mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-08 10:44:09 -04:00
Update Credit Slips
This commit is contained in:
parent
0a05ba617a
commit
a4fe0095df
BIN
resources/images/news/credit_slips.png
Normal file
BIN
resources/images/news/credit_slips.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.7 KiB |
@ -1,35 +1,44 @@
|
||||
#!/usr/bin/env python
|
||||
__license__ = 'GPL 3'
|
||||
__copyright__ = 'zotzot'
|
||||
__copyright__ = 'zotzo'
|
||||
__docformat__ = 'restructuredtext en'
|
||||
|
||||
from calibre.web.feeds.news import BasicNewsRecipe
|
||||
|
||||
|
||||
class CreditSlips(BasicNewsRecipe):
|
||||
__license__ = 'GPL v3'
|
||||
__author__ = 'zotzot'
|
||||
language = 'en'
|
||||
version = 1
|
||||
__author__ = 'zotzot'
|
||||
version = 2
|
||||
title = u'Credit Slips.org'
|
||||
publisher = u'Bankr-L'
|
||||
category = u'Economic blog'
|
||||
description = u'All things about credit.'
|
||||
cover_url = 'http://bit.ly/hyZSTr'
|
||||
oldest_article = 50
|
||||
description = u'A discussion on credit and bankruptcy'
|
||||
cover_url = 'http://bit.ly/eAKNCB'
|
||||
oldest_article = 15
|
||||
max_articles_per_feed = 100
|
||||
use_embedded_content = True
|
||||
no_stylesheets = True
|
||||
remove_javascript = True
|
||||
|
||||
conversion_options = {
|
||||
'comments': description,
|
||||
'tags': category,
|
||||
'language': 'en',
|
||||
'publisher': publisher,
|
||||
}
|
||||
|
||||
feeds = [
|
||||
(u'Credit Slips', u'http://www.creditslips.org/creditslips/atom.xml')
|
||||
]
|
||||
conversion_options = {
|
||||
'comments': description,
|
||||
'tags': category,
|
||||
'language': 'en',
|
||||
'publisher': publisher
|
||||
}
|
||||
extra_css = '''
|
||||
body{font-family:verdana,arial,helvetica,geneva,sans-serif;}
|
||||
img {float: left; margin-right: 0.5em;}
|
||||
'''
|
||||
(u'Credit Slips', u'http://www.creditslips.org/creditslips/atom.xml')
|
||||
]
|
||||
|
||||
extra_css = '''
|
||||
.author {font-family:Helvetica,sans-serif; font-weight:normal;font-size:small;}
|
||||
h1 {font-family:Arial,Helvetica,sans-serif; font-weight:bold;font-size:large;}
|
||||
p {font-family:Helvetica,Arial,sans-serif;font-size:small;}
|
||||
body {font-family:Helvetica,Arial,sans-serif;font-size:small;}
|
||||
'''
|
||||
|
||||
def populate_article_metadata(self, article, soup, first):
|
||||
h2 = soup.find('h2')
|
||||
h2.replaceWith(h2.prettify() + '<p><em>Posted by ' + article.author + '</em></p>')
|
||||
|
Loading…
x
Reference in New Issue
Block a user