rrm: Progress info when checksumming.
This commit is contained in:
parent
02896e1eb7
commit
9a39d50440
3
rrm/rrm
3
rrm/rrm
|
@ -55,6 +55,8 @@ use Digest::SHA;
|
|||
my %size;
|
||||
my %hashval;
|
||||
my @remove;
|
||||
my $t = 1;
|
||||
my $totalfiles = @ARGV;
|
||||
for my $file (@ARGV) {
|
||||
if(not -e $file) {
|
||||
warn("File does not exist: $file");
|
||||
|
@ -64,6 +66,7 @@ for my $file (@ARGV) {
|
|||
warn("Not a file: $file");
|
||||
next;
|
||||
}
|
||||
printf("[%d/%d] %s\n", $t++, $totalfiles, $file);
|
||||
if(-s $file > 0) {
|
||||
$size{$file} = -s $file;
|
||||
my $sha = Digest::SHA->new(256);
|
||||
|
|
Loading…
Reference in a new issue