open F, "isdndb.txt" or die "file $file not found"; open G, ">tutu" or die "file $file not found"; foreach () { s/\#.*//; # s/\[City\]\s+National//; /\[Country\]\s*(.*)/ and $country = $1; /\[City\]\s*(.*)/ and $city = $1; /\[Name\]\s*(.*)/ and $name = $1; /\[Prefix\]\s*(.*)/ and $prefix = $1; /\[ISDN\]\s*(.*)/ and $isdn = $1; /\[Encaps\]\s*.*/ and do { defined $dns1 and $dns2=""; }; /\[Domain\]\s*(.*)/ and $domain = $1; /\[DNS\]\s*(.*)/ and ($dns1 ? $dns2 : $dns1) = $1; /\[End\]\s*(.*)/ and do { undef $name; undef $prefix; undef $isdn; undef $domain; undef $dns1; undef $dns2; }; if ($isdn && !$prefix) { $prefix = "" } if (defined $name && defined $isdn && defined $domain && defined $dns1 && defined $dns2) { print G join("|", $country, $city, join("=>", $name, $prefix . $isdn, $domain, $dns1, $dns2)), "\n"; undef $name; undef $prefix; undef $isdn; undef $domain; undef $dns1; undef $dns2; } } distro/mdv2008.0 Mageia Installer and base platform for many utilitiesThierry Vignaud [tv]
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2005-04-25 10:19:31 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2005-04-25 10:19:31 +0000
commited90eab03bfceee7ae91700d4451fc8ddb54f8cc (patch)
treec9b29a037f3de30e9ae1423a85a6e61af9380554
parent3cd40ab8ab270b9a19083099ceb1b4eccbbb5247 (diff)
downloaddrakx-ed90eab03bfceee7ae91700d4451fc8ddb54f8cc.tar
drakx-ed90eab03bfceee7ae91700d4451fc8ddb54f8cc.tar.gz
drakx-ed90eab03bfceee7ae91700d4451fc8ddb54f8cc.tar.bz2
drakx-ed90eab03bfceee7ae91700d4451fc8ddb54f8cc.tar.xz
drakx-ed90eab03bfceee7ae91700d4451fc8ddb54f8cc.zip
sync with copyright bumping