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; } } /mdv2007.1 Mageia Installer and base platform for many utilitiesThierry Vignaud [tv]
summaryrefslogtreecommitdiffstats
path: root/perl-install/install/share
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2008-08-12 15:56:12 +0000
committerThierry Vignaud <tv@mandriva.org>2008-08-12 15:56:12 +0000
commitb731540d31acd92cfc96188925d3c733ad9102cf (patch)
treeb888141c939fa44f7ec50e0b342235bb4fd99548 /perl-install/install/share
parentea701902bc237d6f335c1cc471b3c2d3fff591b4 (diff)
downloaddrakx-b731540d31acd92cfc96188925d3c733ad9102cf.tar
drakx-b731540d31acd92cfc96188925d3c733ad9102cf.tar.gz
drakx-b731540d31acd92cfc96188925d3c733ad9102cf.tar.bz2
drakx-b731540d31acd92cfc96188925d3c733ad9102cf.tar.xz
drakx-b731540d31acd92cfc96188925d3c733ad9102cf.zip
sync with code
Diffstat (limited to 'perl-install/install/share')