mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Merge from trunk
This commit is contained in:
commit
8c69264dcc
@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
__license__ = 'GPL v3'
|
__license__ = 'GPL v3'
|
||||||
__copyright__ = '2010, Darko Miletic <darko.miletic at gmail.com>'
|
__copyright__ = '2010, Darko Miletic <darko.miletic at gmail.com>'
|
||||||
'''
|
'''
|
||||||
@ -18,11 +17,17 @@ class Berlingske_dk(BasicNewsRecipe):
|
|||||||
no_stylesheets = True
|
no_stylesheets = True
|
||||||
remove_empty_feeds = True
|
remove_empty_feeds = True
|
||||||
use_embedded_content = False
|
use_embedded_content = False
|
||||||
|
remove_javascript = True
|
||||||
publication_type = 'newspaper'
|
publication_type = 'newspaper'
|
||||||
encoding = 'utf8'
|
encoding = 'utf8'
|
||||||
language = 'da'
|
language = 'da'
|
||||||
masthead_url = 'http://www.berlingske.dk/sites/all/themes/bm/img/layout/masthead_bg.gif'
|
auto_cleanup = True
|
||||||
extra_css = ' body{font-family: Arial,Helvetica,sans-serif } h1,.manchet,.byline{font-family: Cambria,Georgia,Times,"Times New Roman",serif } '
|
extra_css = '''
|
||||||
|
.manchet {color:#888888;}
|
||||||
|
.dateline {font-size: x-small; color:#444444;}
|
||||||
|
.manchet,.dateline { font-family: Cambria,Georgia,Times,"Times New Roman",serif }
|
||||||
|
.body {font-family: Arial,Helvetica,sans-serif }
|
||||||
|
'''
|
||||||
|
|
||||||
conversion_options = {
|
conversion_options = {
|
||||||
'comment' : description
|
'comment' : description
|
||||||
@ -32,18 +37,14 @@ class Berlingske_dk(BasicNewsRecipe):
|
|||||||
}
|
}
|
||||||
|
|
||||||
feeds = [
|
feeds = [
|
||||||
(u'Breaking news' , u'http://www.berlingske.dk/breaking/rss' )
|
(u'Breaking news' , u'http://www.b.dk/breaking/rss' )
|
||||||
,(u'Seneste nyt' , u'http://www.berlingske.dk/seneste/rss' )
|
,(u'Seneste nyt' , u'http://www.b.dk/seneste/rss' )
|
||||||
,(u'Topnyheder' , u'http://www.berlingske.dk/top/rss' )
|
,(u'Topnyheder' , u'http://www.b.dk/top/rss' )
|
||||||
,(u'Danmark' , u'http://www.berlingske.dk/danmark/seneste/rss' )
|
,(u'Danmark' , u'http://www.b.dk/danmark/seneste/rss' )
|
||||||
,(u'Verden' , u'http://www.berlingske.dk/verden/seneste/rss' )
|
,(u'Verden' , u'http://www.b.dk/verden/seneste/rss' )
|
||||||
,(u'Klima' , u'http://www.berlingske.dk/klima/seneste/rss' )
|
,(u'Klima' , u'http://www.b.dk/klima/seneste/rss' )
|
||||||
,(u'Debat' , u'http://www.berlingske.dk/debat/seneste/rss' )
|
,(u'Debat' , u'http://www.b.dk/debat/seneste/rss' )
|
||||||
,(u'Koebenhavn' , u'http://www.berlingske.dk/koebenhavn/seneste/rss')
|
,(u'Koebenhavn' , u'http://www.b.dk/koebenhavn/seneste/rss')
|
||||||
,(u'Politik' , u'http://www.berlingske.dk/politik/seneste/rss' )
|
,(u'Politik' , u'http://www.b.dk/politik/seneste/rss' )
|
||||||
,(u'Kultur' , u'http://www.berlingske.dk/kultur/seneste/rss' )
|
,(u'Kultur' , u'http://www.b.dk/kultur/seneste/rss' )
|
||||||
]
|
]
|
||||||
|
|
||||||
keep_only_tags = [dict(attrs={'class':['first','pt-article']})]
|
|
||||||
remove_tags = [dict(name=['object','link','base','iframe','embed'])]
|
|
||||||
|
|
||||||
|
50
recipes/techtarget.recipe
Normal file
50
recipes/techtarget.recipe
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
from calibre.web.feeds.news import BasicNewsRecipe
|
||||||
|
|
||||||
|
class TechTarget(BasicNewsRecipe):
|
||||||
|
title = u'Techtarget'
|
||||||
|
__author__ = 'Julio:map'
|
||||||
|
description = '''IT Infrastructure related blogs
|
||||||
|
from Techtarget'''
|
||||||
|
publisher = 'Techtarget'
|
||||||
|
language = 'en'
|
||||||
|
category = 'IT, Infrastructure'
|
||||||
|
oldest_article = 7
|
||||||
|
max_articles_per_feed = 100
|
||||||
|
no_stylesheets = True
|
||||||
|
use_embedded_content = False
|
||||||
|
needs_subscription = True
|
||||||
|
auto_cleanup = False
|
||||||
|
LOGIN = u'http://searchservervirtualization.techtarget.com/login'
|
||||||
|
|
||||||
|
def get_browser(self):
|
||||||
|
br = BasicNewsRecipe.get_browser()
|
||||||
|
if self.username is not None:
|
||||||
|
br.open(self.LOGIN)
|
||||||
|
br.select_form(nr=1)
|
||||||
|
br['email'] = self.username
|
||||||
|
if self.password is not None:
|
||||||
|
br['password'] = self.password
|
||||||
|
br.submit()
|
||||||
|
return br
|
||||||
|
|
||||||
|
keep_only_tags = [dict(name='div', attrs={'id':'article'})]
|
||||||
|
remove_tags= [dict(name='div', attrs={'id':['articleToolbar','relatedContent']})]
|
||||||
|
remove_tags_after = [dict(name='div', attrs={'id':'relatedContent'})]
|
||||||
|
|
||||||
|
|
||||||
|
feeds = [
|
||||||
|
(u'IT news and analysis for CIOs', u'http://feeds.pheedo.com/SearchCIOITNewsAndAnalysisForCIOs'),
|
||||||
|
(u'TotalCIO', u'http://feeds.pheedo.com/1532.xml'),
|
||||||
|
(u'SearchCIO-Midmarket: Technology news and tips for midmarket CIOs', u'http://feeds.pheedo.com/techtarget/Searchsmb/Smbs'),
|
||||||
|
(u'Compliance news and advice for senior IT and business managers', u'http://feeds.pheedo.com/tt/1200'),
|
||||||
|
(u'Server virtualization news and opinions', u'http://feeds.pheedo.com/SearchservervirtualizationServerVirtualizationNewsAndOpinions'),
|
||||||
|
(u'The Virtualization Room', u'http://feeds.pheedo.com/techtarget/nzLe'),
|
||||||
|
(u'Server virtualization technical tips and expert advice', u'http://feeds.pheedo.com/SearchservervirtualizationServerVirtualizationTechnicalTipsAndExpertAdvice'),
|
||||||
|
(u'Cloud Computing news and Technical Advice', u'http://feeds.pheedo.com/1260'),
|
||||||
|
(u'IT infrastructure news', u'http://feeds.pheedo.com/techtarget/Searchdatacenter/ItInfrastructure'),
|
||||||
|
(u'Storage Channel Update', u'http://feeds.pheedo.com/ChannelMarker-TheItChannelWeblog'),
|
||||||
|
(u'VMware Tips and News', u'http://feeds.pheedo.com/SearchvmwarecomVmwareTipsAndTricks'),
|
||||||
|
(u'Enterprise IT news roundup', u'http://feeds.pheedo.com/WhatisEnterpriseItNewsRoundup'),
|
||||||
|
(u'WhatIs: Enterprise IT tips and expert advice', u'http://feeds.pheedo.com/WhatisEnterpriseItTipsAndExpertAdvice'),
|
||||||
|
(u'WhatIs: Enterprise IT news roundup', u'http://feeds.pheedo.com/WhatisEnterpriseItNewsRoundup'),
|
||||||
|
]
|
Loading…
x
Reference in New Issue
Block a user