Dolda2000 GitWeb
/
utils.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix theme regex.
[utils.git]
/
ANN.pm
diff --git
a/ANN.pm
b/ANN.pm
index
dfa4b41
..
020c547
100644
(file)
--- a/
ANN.pm
+++ b/
ANN.pm
@@
-98,8
+98,8
@@
sub getthemes
my(@parts, $ct, $buf);
while($html =~ /\G\<br\> (([^<>]|\<i\>|<\/i>)+)/igc) {
$buf = $1;
my(@parts, $ct, $buf);
while($html =~ /\G\<br\> (([^<>]|\<i\>|<\/i>)+)/igc) {
$buf = $1;
- # 0 1 2 3 4 5 6 7
8 9 10
11
- if(@parts = ($buf =~ /(\#(\d+):)?\s*\"([^\"\(]+)(\s
+
\((\<i\>(.*)<\/i>(;\s*)?)?([^<>]+)?\))?\"\s+by\s+([^\(]*[^\(\s])(\s*\(eps (\d+)-(\d+)?\))?/i)) {
+ # 0 1 2 3 4 5 6 7
8 9 10
11
+ if(@parts = ($buf =~ /(\#(\d+):)?\s*\"([^\"\(]+)(\s
*
\((\<i\>(.*)<\/i>(;\s*)?)?([^<>]+)?\))?\"\s+by\s+([^\(]*[^\(\s])(\s*\(eps (\d+)-(\d+)?\))?/i)) {
$ct = {};
$ct->{"num"} = $parts[1] if defined $parts[1];
if(defined $parts[5]) {
$ct = {};
$ct->{"num"} = $parts[1] if defined $parts[1];
if(defined $parts[5]) {
@@
-142,6
+142,9
@@
sub getseries
if(($buf) = ($html =~ /number of episodes:<\/b>\n([^<]+)</is)) {
$ret{"eps"} = $buf;
}
if(($buf) = ($html =~ /number of episodes:<\/b>\n([^<]+)</is)) {
$ret{"eps"} = $buf;
}
+ if(($buf) = ($html =~ /genres:<\/b>\n([^<]+)</is)) {
+ $ret{"gnr"} = [split /, /, $buf];
+ }
$buf = getthemes $html, "opening";
$ret{"op"} = $buf if(@{$buf});
$buf = getthemes $html, "ending";
$buf = getthemes $html, "opening";
$ret{"op"} = $buf if(@{$buf});
$buf = getthemes $html, "ending";