--- /dev/null
+# -*-perl-*-
+# keitairc/lib/plugins/30prefectures
+#
+# ¸©Ì¾¤«¤é»Ï¤Þ¤ëʸ»úÎó¤ò·ÈÂÓÈÇGoogle Map¤Ë¥ê¥ó¥¯
+# $Id: 30prefectures,v 1.1 2008-01-14 05:22:44 morimoto Exp $
+# $Source: /home/ishikawa/work/keitairc/tmp/keitairc/lib/plugins/30prefectures,v $
+
+$plugin = {
+ name => 'prefectures',
+
+ message_replace_regexp => '(Ë̳¤Æ»|µþÅÔÉÜ|ÂçºåÉÜ|ÅìµþÅÔ|ÀÄ¿¹¸©|´ä¼ê¸©|µÜ¾ë¸©|½©Åĸ©|»³·Á¸©|Ê¡Å縩|°ñ¾ë¸©|ÆÊÌÚ¸©|·²Çϸ©|ºë¶Ì¸©|ÀéÍÕ¸©|¿ÀÆàÀ|¿·³ã¸©|ÉÙ»³¸©|ÀÐÀ|Ê¡°æ¸©|»³Íü¸©|ĹÌ|´ôÉ츩|ÀŲ¬¸©|°¦Ãθ©|»°½Å¸©|¼¢²ì¸©|ʼ¸Ë¸©|ÆàÎɸ©|Ï²λ³¸©|Ä»¼è¸©|Å纬¸©|²¬»³¸©|¹Å縩|»³¸ý¸©|ÆÁÅ縩|¹áÀ|°¦É²¸©|¹âÃθ©|Ê¡²¬¸©|º´²ì¸©|Ĺºê¸©|·§Ëܸ©|Âçʬ¸©|µÜºê¸©|¼¯»ùÅ縩|²Æ츩)(.*)',
+ message_replace_imprementation => sub {
+ my ($session_id, $p1, $p2) = @_;
+ my $str = $p1 . $p2;
+ my $tmp = $str;
+ Encode::from_to($tmp, 'euc-jp', 'shiftjis');
+ my $tmp = ::uri_escape($tmp);
+ sprintf('<a href="http://www.google.co.jp/m/lcb?mp=1&uipref=3&source=m&ie=Shift_JIS&action=chgloc&loc=%s">%s</a>', $tmp, $str);
+ },
+};
+
+1;
+
+
--- /dev/null
+# -*-perl-*-
+# keitairc/lib/plugins/31distinct
+#
+# ¶è̾¤«¤é»Ï¤Þ¤ëʸ»úÎó¤ò·ÈÂÓÈÇGoogle Map¤Ë¥ê¥ó¥¯
+# TODO: ÅìµþÅԤζ褷¤«¤Ï¤¤¤Ã¤Æ¤Ê¤¤¤è
+# $Id: 31distinct,v 1.1 2008-01-14 05:22:44 morimoto Exp $
+# $Source: /home/ishikawa/work/keitairc/tmp/keitairc/lib/plugins/31distinct,v $
+
+
+my $tokyo_special_wards = 'ÀéÂåÅĶè|Ãæ±û¶è|¹Á¶è|¿·½É¶è|ʸµþ¶è|ÂæÅì¶è|ËÏÅĶè|¹¾Åì¶è|ÉÊÀî¶è|Ìܹõ¶è|ÂçÅĶè|À¤ÅÄë¶è|½Âë¶è|ÃæÌî¶è|¿ùʶè|ËÅç¶è|Ë̶è|¹ÓÀî¶è|ÈĶ¶¶è|ÎýÇ϶è|ÂΩ¶è|³ë¾þ¶è|¹¾¸ÍÀî¶è';
+my $tokyo_cities = '¾¼Åç»Ô|¤¢¤¤ëÌî»Ô|°ð¾ë»Ô|ÀÄÇß»Ô|À¶À¥»Ô|¹ñΩ»Ô|¾®¶â°æ»Ô|¹ñʬ»û»Ô|¾®Ê¿»Ô|¹ý¹¾»Ô|ΩÀî»Ô|¿Ëà»Ô|Ä´ÉÛ»Ô|À¾Åìµþ»Ô|Ȭ²¦»Ò»Ô|±©Â¼»Ô|Åìµ×αÊÆ»Ô|Åì¼»³»Ô|ÅìÂçÏ»Ô|ÆüÌî»Ô|ÉÜÃæ»Ô|Ê¡À¸»Ô|Ä®ÅÄ»Ô|»°Âë»Ô|Éð¢Ìî»Ô|É𢼻³»Ô';
+
+$plugin = {
+ name => 'distinct',
+
+ message_replace_regexp => '(' . $tokyo_special_wards . '|' . $tokyo_cities . ')(.*)',
+ message_replace_imprementation => sub {
+ my ($session_id, $p1, $p2) = @_;
+ my $str = $p1 . $p2;
+ my $tmp = $str;
+ Encode::from_to($tmp, 'euc-jp', 'shiftjis');
+ my $tmp = ::uri_escape($tmp);
+ sprintf('<a href="http://www.google.co.jp/m/lcb?mp=1&uipref=3&source=m&ie=Shift_JIS&action=chgloc&loc=%s">%s</a>', $tmp, $str);
+ },
+};
+
+1;
+
+