@@ 4312-4328 (lines=17) @@ | ||
4309 | class HarkAVagrant(GenericTumblrV1): |
|
4310 | """Class to retrieve Hark A Vagrant comics.""" |
|
4311 | # Also on http://www.harkavagrant.com |
|
4312 | name = 'hark-tumblr' |
|
4313 | long_name = 'Hark A Vagrant (from Tumblr)' |
|
4314 | url = 'http://beatonna.tumblr.com' |
|
4315 | ||
4316 | ||
4317 | class OurSuperAdventureTumblr(GenericTumblrV1): |
|
4318 | """Class to retrieve Our Super Adventure comics.""" |
|
4319 | # Also on https://tapastic.com/series/Our-Super-Adventure |
|
4320 | # Also on http://www.oursuperadventure.com |
|
4321 | # http://sarahgraley.com |
|
4322 | name = 'superadventure-tumblr' |
|
4323 | long_name = 'Our Super Adventure (from Tumblr)' |
|
4324 | url = 'http://sarahssketchbook.tumblr.com' |
|
4325 | ||
4326 | ||
4327 | class JakeLikesOnions(GenericTumblrV1): |
|
4328 | """Class to retrieve Jake Likes Onions comics.""" |
|
4329 | name = 'jake' |
|
4330 | long_name = 'Jake Likes Onions' |
|
4331 | url = 'http://jakelikesonions.com' |
|
@@ 730-745 (lines=16) @@ | ||
727 | class NeDroid(GenericNavigableComic): |
|
728 | """Class to retrieve NeDroid comics.""" |
|
729 | name = 'nedroid' |
|
730 | long_name = 'NeDroid' |
|
731 | url = 'http://nedroid.com' |
|
732 | get_first_comic_link = get_div_navfirst_a |
|
733 | get_navi_link = get_link_rel_next |
|
734 | get_url_from_link = join_cls_url_to_href |
|
735 | ||
736 | @classmethod |
|
737 | def get_comic_info(cls, soup, link): |
|
738 | """Get information about a particular comics.""" |
|
739 | short_url_re = re.compile('^%s/\\?p=([0-9]*)' % cls.url) |
|
740 | short_url = cls.get_url_from_link(soup.find('link', rel='shortlink')) |
|
741 | num = int(short_url_re.match(short_url).groups()[0]) |
|
742 | imgs = soup.find('div', id='comic').find_all('img') |
|
743 | assert len(imgs) == 1 |
|
744 | title = imgs[0]['alt'] |
|
745 | title2 = imgs[0]['title'] |
|
746 | return { |
|
747 | 'short_url': short_url, |
|
748 | 'title': title, |