| 1 | #! perl | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | |||
| 6 | package Comics::Plugin::LeastICouldDo; | ||
| 7 | |||
| 8 | use parent qw(Comics::Fetcher::Cascade); | ||
| 9 | |||
| 10 | our $VERSION = "1.04"; | ||
| 11 | |||
| 12 | our $name = "Least I Could Do"; | ||
| 13 | our $url = "https://www.leasticoulddo.com/"; | ||
| 14 | our @patterns = | ||
| 15 | ( qr{ <a \s+ | ||
| 16 | href="(?<url>https?://(?:www.)?leasticoulddo.com/comic/\d+/?)" \s+ | ||
| 17 | id="latest-comic"> | ||
| 18 | }six, | ||
| 19 | qr{ <meta \s+ | ||
| 20 | property="og:description" \s+ | ||
| 21 | content="(?<title>.*?)" \s* | ||
| 22 | /> | ||
| 23 | .*? | ||
| 24 | <meta \s+ | ||
| 25 | property="og:image" \s+ | ||
| 26 | content="(?<url>https?://(?:www.)?leasticoulddo.com/wp-content/uploads/ | ||
| 27 | \d+/\d+/(?<image>.*?\.\w+))" \s* | ||
| 28 | /> | ||
| 29 | }six, | ||
| 30 | ); | ||
| 31 | |||
| 32 | # Important: Return the package name! | ||
| 33 | __PACKAGE__; |