Changeset 4378

Show
Ignore:
Timestamp:
01/10/08 23:34:32 (10 months ago)
Author:
yto
Message:

lang/perl/misc/wikipejago/ext-wpj-person.pl: ALL person name.

Location:
lang/perl/misc/wikipejago
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • lang/perl/misc/wikipejago/ChangeLog

    r3802 r4378  
     12008-01-10  yto  <yto at nais dot to> 
     2 
     3        * ext-wpj-person.pl: Japanese person name => All person name. 
     4 
    152007-12-30  yto  <yto at nais dot to> 
    26 
  • lang/perl/misc/wikipejago/ext-wpj-person.pl

    r3802 r4378  
    11#!/usr/bin/perl 
    2 # ウィキペディア (http://ja.wikipedia.org/) から日本人の人名っぽいのを取り出す 
     2# ウィキペディア (http://ja.wikipedia.org/) から人名っぽいのを取り出す 
    33# [Step.1] 
    44# wget http://download.wikimedia.org/jawiki/latest/jawiki-latest-pages-articles.xml.bz2 
     
    2121        my $title = $1; 
    2222        next if $title =~ m{^([^<]+:|\d{4})}; 
    23         if ($page =~ m{(Category:\d+年生|\| Born)} 
    24             and $page =~ m{Category:日本} 
    25             and $page !~ m{Category:日本生産} 
     23        if ($page =~ m{(Category:\d+年生)} 
     24            and $page !~ m{Category:[^\|]*(犬|馬)[\|\]]} 
    2625            ) { 
    2726            $title =~ s/\s+\(.+?\)\s*$//;