mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
too little content
This commit is contained in:
parent
7206ea1250
commit
a65292eb46
Binary file not shown.
Before Width: | Height: | Size: 466 B |
@ -1,36 +0,0 @@
|
||||
from calibre.web.feeds.news import BasicNewsRecipe
|
||||
|
||||
|
||||
class OSWorld(BasicNewsRecipe):
|
||||
title = u'OSWorld.pl'
|
||||
__author__ = 'fenuks'
|
||||
description = u'OSWorld.pl to serwis internetowy, dzięki któremu poznasz czym naprawdę jest Open Source. Serwis poświęcony jest wolnemu oprogramowaniu jak linux mint, centos czy ubunty. Znajdziecie u nasz artykuły, unity oraz informacje o certyfikatach CACert. OSWorld to mały świat wielkich systemów!' # noqa
|
||||
category = 'OS, IT, open source, Linux'
|
||||
language = 'pl'
|
||||
cover_url = 'http://osworld.pl/wp-content/uploads/osworld-kwadrat-128x111.png'
|
||||
extra_css = 'img.alignleft {float: left; margin-right: 5px;}'
|
||||
oldest_article = 7
|
||||
max_articles_per_feed = 100
|
||||
no_stylesheets = True
|
||||
remove_empty_feeds = True
|
||||
use_embedded_content = False
|
||||
keep_only_tags = [dict(id=['dzial', 'posts'])]
|
||||
remove_tags = [dict(attrs={'class': 'post-comments'})]
|
||||
remove_tags_after = dict(attrs={'class': 'entry clr'})
|
||||
feeds = [(u'Artyku\u0142y', u'http://osworld.pl/category/artykuly/feed/'),
|
||||
(u'Nowe wersje', u'http://osworld.pl/category/nowe-wersje/feed/')]
|
||||
|
||||
def append_page(self, soup, appendtag):
|
||||
tag = appendtag.find(attrs={'id': 'paginacja'})
|
||||
if tag:
|
||||
for nexturl in tag.findAll('a'):
|
||||
soup2 = self.index_to_soup(nexturl['href'])
|
||||
pagetext = soup2.find(attrs={'class': 'entry clr'})
|
||||
pos = len(appendtag.contents)
|
||||
appendtag.insert(pos, pagetext)
|
||||
for r in appendtag.findAll(attrs={'id': 'paginacja'}):
|
||||
r.extract()
|
||||
|
||||
def preprocess_html(self, soup):
|
||||
self.append_page(soup, soup.body)
|
||||
return soup
|
Loading…
x
Reference in New Issue
Block a user