# -*- coding: iso-8859-1 -*- # Copyright (C) 2004-2005 Tristan Seligmann and Jonathan Jacobs # Copyright (C) 2012 Bastian Kleineidam from re import compile from ..scraper import _BasicScraper from ..helpers import indirectStarter from ..util import tagre class Galaxion(_BasicScraper): latestUrl = 'http://galaxioncomics.com/' stripUrl = latestUrl + '%s/' imageSearch = compile(tagre("img", "src", r'(http://galaxioncomics\.com/comics/[^"]+)')) prevSearch = compile(tagre("a", "href", r'(http://galaxioncomics\.com/[^"]+)', after="prev")) help = 'Index format: n-comic/book-n/chapter-n/title-nnn' class Garanos(_BasicScraper): starter = indirectStarter('http://garanos.alexheberling.com/pages/page-1/', compile(tagre("a", "href", r'(http://garanos\.alexheberling\.com/pages/[^"]+)', after="navi-last"))) stripUrl = 'http://garanos.alexheberling.com/pages/page-%s' imageSearch = compile(tagre("img", "src", r'(http://garanos\.alexheberling\.com/comics/[^"]+)')) prevSearch = compile(tagre("a", "href", r'(http://garanos\.alexheberling\.com/pages/[^"]+)', after="prev")) help = 'Index format: n (unpadded)' class GUComics(_BasicScraper): latestUrl = 'http://www.gucomics.com/comic/' stripUrl = latestUrl + '?cdate=%s' imageSearch = compile(r' ') help = 'Index format: yymmdd' class GoneWithTheBlastwave(_BasicScraper): starter = indirectStarter('http://www.blastwave-comic.com/index.php?p=comic&nro=1', compile(r'href="(index.php\?p=comic&nro=\d+)">]*>(?!
)') prevSearch = compile(r'
« Previous') help = 'Index format: nnn' class GlassHalfEmpty(_BasicScraper): latestUrl = 'http://www.defectivity.com/ghe/index.php' stripUrl = latestUrl + '?strip_id=%s' imageSearch = compile(r'src="(comics/.+?)"') prevSearch = compile(tagre("a", "href", r'(\?strip_id=\d+)') + tagre("img", "src", r'\.\./images/arrowbuttons/onback\.jpg')) help = 'Index format: nnn' class GreystoneInn(_BasicScraper): latestUrl = 'http://www.greystoneinn.net/' stripUrl = latestUrl + 'd/%s.html' imageSearch=compile(tagre("img", "src", r'(/comic[s|/][^"]+)')) prevSearch=compile(tagre("a", "href", r'[^"]*(/d/\d+\.s?html)')+r"[^>]+/images/(?:nav_02|previous_day)\.gif") help='Index format: yyyymmdd'