diff --git a/src/calibre/debug.py b/src/calibre/debug.py index 35fc615b58..ac164c14ab 100644 --- a/src/calibre/debug.py +++ b/src/calibre/debug.py @@ -105,7 +105,7 @@ def debug_device_driver(): prefix = logical_disk.DeviceID+os.sep drives.append((str(drive.PNPDeviceID), drive.Index, prefix)) except IndexError: - drives.append(str(drive.PNPDeviceID)) + drives.append((str(drive.PNPDeviceID), 'No mount points found')) for drive in drives: print '\t', drive from calibre.devices import devices diff --git a/src/calibre/web/feeds/recipes/__init__.py b/src/calibre/web/feeds/recipes/__init__.py index dc848fe4b9..73b0e67122 100644 --- a/src/calibre/web/feeds/recipes/__init__.py +++ b/src/calibre/web/feeds/recipes/__init__.py @@ -40,7 +40,7 @@ recipe_modules = ['recipe_' + r for r in ( 'krstarica', 'krstarica_en', 'tanjug', 'laprensa_ni', 'azstarnet', 'corriere_della_sera_it', 'corriere_della_sera_en', 'msdnmag_en', 'moneynews', 'der_standard', 'diepresse', 'nzz_ger', 'hna', - 'seattle_times', 'scott_hanselman', 'coding_horror', + 'seattle_times', 'scott_hanselman', 'coding_horror', 'twitchfilms', 'stackoverflow', 'telepolis_artikel', 'zaobao', 'usnews', )] diff --git a/src/calibre/web/feeds/recipes/recipe_twitchfilms.py b/src/calibre/web/feeds/recipes/recipe_twitchfilms.py new file mode 100644 index 0000000000..dc0bcac88b --- /dev/null +++ b/src/calibre/web/feeds/recipes/recipe_twitchfilms.py @@ -0,0 +1,41 @@ +#!/usr/bin/env python + +__license__ = 'GPL v3' +__copyright__ = '2009, Darko Miletic ' +''' +twitchfilm.net/site/ +''' +from calibre.web.feeds.news import BasicNewsRecipe +from calibre.ebooks.BeautifulSoup import BeautifulSoup, Tag + +class Twitchfilm(BasicNewsRecipe): + title = 'Twitch Films' + __author__ = 'Darko Miletic' + description = 'Twitch specializes in spreading the news on strange little films from around the world.' + oldest_article = 30 + max_articles_per_feed = 100 + no_stylesheets = True + use_embedded_content = True + encoding = 'utf-8' + publisher = 'Twitch' + category = 'twitch, twitchfilm, movie news, movie reviews, cult cinema, independent cinema, anime, foreign cinema, geek talk' + language = _('English') + + html2lrf_options = [ + '--comment', description + , '--category', category + , '--publisher', publisher + ] + + html2epub_options = 'publisher="' + publisher + '"\ncomments="' + description + '"\ntags="' + category + '"' + + remove_tags = [dict(name='div', attrs={'class':'feedflare'})] + + feeds = [(u'News', u'http://feedproxy.google.com/TwitchEverything')] + + def preprocess_html(self, soup): + mtag = Tag(soup,'meta',[('http-equiv','Content-Type'),('context','text/html; charset=utf-8')]) + soup.head.insert(0,mtag) + soup.html['lang'] = 'en-US' + return soup +