85 |
sub restore_increment { |
sub restore_increment { |
86 |
my $path = shift || die "need path!"; |
my $path = shift || die "need path!"; |
87 |
|
|
88 |
|
if ($path !~ m/\.tar\.gz$/i) { |
89 |
|
print "skipping $path, not .tar.gz increment\n"; |
90 |
|
return; |
91 |
|
} |
92 |
|
|
93 |
print "working on $path\n"; |
print "working on $path\n"; |
94 |
|
|
95 |
if (-e $restore_path) { |
if (-e $restore_path) { |
142 |
restore_increment( $File::Find::name ); |
restore_increment( $File::Find::name ); |
143 |
}, follow => 0 }, $restore_inc); |
}, follow => 0 }, $restore_inc); |
144 |
|
|
145 |
} elsif (-f $restore_inc && $restore_inc =~ m/\.tar\.gz$/i) { |
} elsif (-f $restore_inc) { |
146 |
restore_increment( $restore_inc ); |
restore_increment( $restore_inc ); |
147 |
} else { |
} else { |
148 |
warn "skipped: $restore_inc, not directory or .tar.gz increment\n"; |
warn "skipped: $restore_inc, not file or directory\n"; |
149 |
} |
} |
150 |
|
|
151 |
} |
} |