changed to older File::Path
authorHeiko Schlittermann <hs@schlittermann.de>
Tue, 25 Jan 2011 23:52:02 +0100
changeset 103 0c9f37c94f0c
parent 102 3000f3962b14
child 104 3c725372a1ce
changed to older File::Path
bin/zone-mk
bin/zone-rm
t/00-config.t
t/00-perl-c.t
--- a/bin/zone-mk	Tue Jan 25 23:45:14 2011 +0100
+++ b/bin/zone-mk	Tue Jan 25 23:52:02 2011 +0100
@@ -6,7 +6,7 @@
 use Pod::Usage;
 use if $ENV{DEBUG} => "Smart::Comments";
 use Cwd qw(abs_path);
-use File::Path qw(make_path);
+use File::Path;
 use File::Basename;
 use Getopt::Long;
 use Net::LibIDN qw(:all);
@@ -50,7 +50,7 @@
         my $configfile = "$cf{zone_conf_dir}/$zone";
         my $now        = time;
 
-        make_path dirname $zonefile;
+        mkpath dirname $zonefile;
 
         if (-f $zonefile and not $opt_force) {
             say "skipping $utf8zone: zone file '$zonefile' exists.";
--- a/bin/zone-rm	Tue Jan 25 23:45:14 2011 +0100
+++ b/bin/zone-rm	Tue Jan 25 23:52:02 2011 +0100
@@ -3,7 +3,7 @@
 use v5.10;
 use warnings;
 use strict;
-use File::Path qw(remove_tree);
+use File::Path;
 use DNStools::Config qw(get_config);
 use Net::LibIDN qw(:all);
 use Pod::Usage;
@@ -45,7 +45,7 @@
             next if not /^y(?:es)?$/i;
         }
 
-        remove_tree("$cf{master_dir}/$zone", "$cf{zone_conf_dir}/$zone",
+        rmtree("$cf{master_dir}/$zone", "$cf{zone_conf_dir}/$zone",
             { verbose => 1 });
 
     }
--- a/t/00-config.t	Tue Jan 25 23:45:14 2011 +0100
+++ b/t/00-config.t	Tue Jan 25 23:52:02 2011 +0100
@@ -2,8 +2,7 @@
 
 use strict;
 use warnings;
-use Test::More;
-use Pod::Coverage;
+use Test::More qw(no_plan);
 use File::Temp;
 
 BEGIN {
@@ -40,6 +39,3 @@
 ok(%cf, "got config from \$DNSTOOLS_CONF");
 is($cf{abc} => "xyz", "simple value");
 is($cf{other} => "valuewithspace", "spaced value");
-
-
-done_testing();
--- a/t/00-perl-c.t	Tue Jan 25 23:45:14 2011 +0100
+++ b/t/00-perl-c.t	Tue Jan 25 23:52:02 2011 +0100
@@ -2,7 +2,7 @@
 use strict;
 use warnings;
 
-use Test::More;
+use Test::More qw(no_plan);
 use File::Find;
 
 plan skip_all => "no blib directories in \@INC"
@@ -13,5 +13,3 @@
     system("perl -Mblib -c $_ &>/dev/null");
     is($? => 0, "syntax $File::Find::name");
 }, "blib/");
-
-done_testing;