| 1 | #! perl | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | |||
| 6 | package Comics::Plugin::Dilbert; | ||
| 7 | |||
| 8 | # Ceased for political reasons. | ||
| 9 | our $disabled = 1; | ||
| 10 | |||
| 11 | use parent qw(Comics::Fetcher::Single); | ||
| 12 | |||
| 13 | our $VERSION = "1.00"; | ||
| 14 | |||
| 15 | our $name = "Dilbert"; | ||
| 16 | our $url = "http://dilbert.com/"; | ||
| 17 | our $pattern = | ||
| 18 | qr{ <img \s+ | ||
| 19 | class="img-responsive \s img-comic" \s+ | ||
| 20 | width="\d+" \s+ | ||
| 21 | height="\d+" \s+ | ||
| 22 | alt="(?<alt>[^"]+)" \s+ | ||
| 23 | src="(?<url>(?:https?:)?//assets.amuniversal.com/ | ||
| 24 | (?<image>.*?))" \s+ /> | ||
| 25 | }x; | ||
| 26 | |||
| 27 | # Important: Return the package name! | ||
| 28 | __PACKAGE__; |