2020-04-18 11:45:44 +00:00
|
|
|
# SPDX-License-Identifier: MIT
|
2016-10-28 22:21:41 +00:00
|
|
|
# Copyright (C) 2004-2008 Tristan Seligmann and Jonathan Jacobs
|
2014-01-05 15:50:57 +00:00
|
|
|
# Copyright (C) 2012-2014 Bastian Kleineidam
|
2022-06-06 10:08:32 +00:00
|
|
|
# Copyright (C) 2015-2022 Tobias Gruetzmacher
|
2020-01-13 06:34:05 +00:00
|
|
|
# Copyright (C) 2019-2020 Daniel Ring
|
2022-06-06 10:08:32 +00:00
|
|
|
from ..scraper import ParserScraper
|
2012-06-20 19:58:13 +00:00
|
|
|
|
2012-11-28 17:15:12 +00:00
|
|
|
|
2022-06-06 10:08:32 +00:00
|
|
|
class KeenSpot(ParserScraper):
|
2016-10-13 22:14:53 +00:00
|
|
|
multipleImagesPerStrip = True
|
|
|
|
imageSearch = (
|
|
|
|
'//img[contains(@src, "/comics/")]',
|
2020-04-22 05:44:41 +00:00
|
|
|
# Gene Catlow Alternate
|
|
|
|
'//img[contains(@src, "/altcomics/")]',
|
2016-10-13 22:14:53 +00:00
|
|
|
# Shockwave Darkside
|
|
|
|
'//img[contains(@src, "/comics2D/")]',
|
|
|
|
'//img[contains(@src, "com/shockwave")]',
|
|
|
|
# Sore Thumbs
|
|
|
|
'//img[contains(@src, "com/st2")]',
|
|
|
|
# Wayward Sons
|
|
|
|
'//img[contains(@src, "com/2")]',
|
|
|
|
)
|
2016-05-20 23:18:42 +00:00
|
|
|
prevSearch = (
|
2016-10-13 22:14:53 +00:00
|
|
|
'//link[@rel="prev"]',
|
|
|
|
'//a[@rel="prev"]',
|
|
|
|
# Exposure
|
|
|
|
'//a[img[@id="exp29"]]',
|
|
|
|
# Hero By Night
|
|
|
|
'//area[contains(@coords, ",-7,")]',
|
|
|
|
# Katrina
|
|
|
|
'//a[img[@id="katc7"]]',
|
|
|
|
# No Room For Magic, Everyone Loves Adis, Wisdom Of Moo
|
|
|
|
'//a[text()="Previous comic"]',
|
|
|
|
# Supernovas
|
|
|
|
'//a[img[@id="p_top_nav"]]',
|
2012-11-21 20:57:26 +00:00
|
|
|
)
|
2016-05-20 23:18:42 +00:00
|
|
|
help = 'Index format: yyyymmdd'
|
|
|
|
|
2020-04-22 05:44:41 +00:00
|
|
|
def __init__(self, name, sub, last=None, adult=False, path='d/%s.html'):
|
2016-05-20 23:18:42 +00:00
|
|
|
super(KeenSpot, self).__init__('KeenSpot/' + name)
|
|
|
|
self.url = 'http://%s.keenspot.com/' % sub
|
2016-10-13 22:14:53 +00:00
|
|
|
self.stripUrl = self.url + path
|
|
|
|
|
|
|
|
if last:
|
|
|
|
self.url = self.stripUrl % last
|
|
|
|
self.endOfLife = True
|
2012-06-20 19:58:13 +00:00
|
|
|
|
2020-04-22 05:44:41 +00:00
|
|
|
if adult:
|
|
|
|
self.adult = adult
|
|
|
|
|
2016-05-20 23:18:42 +00:00
|
|
|
@classmethod
|
|
|
|
def getmodules(cls):
|
2016-10-13 22:14:53 +00:00
|
|
|
return (
|
|
|
|
# Not on frontpage...
|
|
|
|
cls('Buzzboy', 'buzzboy'),
|
|
|
|
cls('EveryoneLovesAdis', 'adis'),
|
2020-10-11 18:15:27 +00:00
|
|
|
cls('GeneCatlowAlternate', 'genecatlow', last='20170302',
|
|
|
|
adult=True, path='altd/%s.html'),
|
2016-10-13 22:14:53 +00:00
|
|
|
|
2016-05-20 23:18:42 +00:00
|
|
|
# do not edit anything below since these entries are generated from
|
|
|
|
# scripts/update_plugins.sh
|
2016-05-22 20:55:06 +00:00
|
|
|
# START AUTOUPDATE
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('27TwentySeven', 'twenty-seven'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('Avengelyne', 'avengelyne'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('BanzaiGirl', 'banzaigirl'),
|
|
|
|
cls('Barker', 'barkercomic'),
|
|
|
|
cls('ChoppingBlock', 'choppingblock'),
|
|
|
|
cls('ClichFlamb', 'clicheflambe'),
|
|
|
|
cls('CountYourSheep', 'countyoursheep'),
|
2019-06-13 02:26:17 +00:00
|
|
|
cls('CrowScare', 'crowscare', last='20111031'),
|
|
|
|
cls('Dreamless', 'dreamless', last='20100726'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('EverythingJake', 'everythingjake'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('Exposure', 'exposure'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('FallOutToyWorks', 'fallouttoyworks'),
|
|
|
|
cls('FriarAndBrimstone', 'friarandbrimstone'),
|
2019-06-13 02:26:17 +00:00
|
|
|
cls('GeneCatlow', 'genecatlow', last='20170412'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('GodMode', 'godmode'),
|
|
|
|
cls('GreenWake', 'greenwake'),
|
|
|
|
cls('HeadTrip', 'headtrip'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('HeroByNight', 'herobynight'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('HoaxHunters', 'hoaxhunters'),
|
|
|
|
cls('InHere', 'inhere'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('JadeWarriors', 'jadewarriors'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('Katrina', 'katrina'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('LutherStrode', 'lutherstrode'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('MakeshiftMiracle', 'makeshiftmiracle'),
|
|
|
|
cls('Marksmen', 'marksmen'),
|
|
|
|
cls('MarryMe', 'marryme'),
|
|
|
|
cls('MedusasDaughter', 'medusasdaughter'),
|
|
|
|
cls('MonsterMassacre', 'monstermassacre'),
|
2019-06-13 02:26:17 +00:00
|
|
|
cls('MysticRevolution', 'mysticrevolution', path='?cid=%s'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('NoPinkPonies', 'nopinkponies'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('NoRoomForMagic', 'noroomformagic'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('OutThere', 'outthere'),
|
|
|
|
cls('Porcelain', 'porcelain'),
|
2019-07-10 08:05:36 +00:00
|
|
|
cls('ProjectionEdge', 'newshounds'),
|
2019-06-13 02:26:17 +00:00
|
|
|
cls('PunchAnPie', 'punchanpie', path='daily/%s.html'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('QUILTBAG', 'quiltbag'),
|
|
|
|
cls('RedSpike', 'redspike'),
|
|
|
|
cls('RumbleFall', 'rumblefall'),
|
|
|
|
cls('SamuraisBlood', 'samuraisblood'),
|
|
|
|
cls('Sharky', 'sharky'),
|
2019-06-13 02:26:17 +00:00
|
|
|
cls('ShockwaveDarkside', 'shockwave', path='2d/%s.html'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('SomethingHappens', 'somethinghappens'),
|
|
|
|
cls('SoreThumbs', 'sorethumbs'),
|
|
|
|
cls('Striptease', 'striptease'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('Supernovas', 'supernovas'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('Superosity', 'superosity'),
|
|
|
|
cls('TheFirstDaughter', 'thefirstdaughter'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('TheHopeVirus', 'hopevirus'),
|
|
|
|
cls('TheHuntersOfSalamanstra', 'salamanstra'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('TheLounge', 'thelounge'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('TheVault', 'thevault'),
|
|
|
|
cls('WaywardSons', 'waywardsons'),
|
|
|
|
cls('WeirdingWillows', 'weirdingwillows'),
|
2016-05-20 23:18:42 +00:00
|
|
|
cls('WICKEDPOWERED', 'wickedpowered'),
|
2016-10-13 22:14:53 +00:00
|
|
|
cls('WisdomOfMoo', 'wisdomofmoo'),
|
2016-05-22 20:55:06 +00:00
|
|
|
# END AUTOUPDATE
|
2016-10-13 22:14:53 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
def shouldSkipUrl(self, url, data):
|
|
|
|
return url in (
|
|
|
|
'http://sorethumbs.keenspot.com/d/20160117.html'
|
|
|
|
)
|