Skip to content
Snippets Groups Projects
Commit 141d85a1 authored by Gerhard Gonter's avatar Gerhard Gonter :speech_balloon:
Browse files

format changes

parent b3f002dd
No related branches found
No related tags found
No related merge requests found
#
# $Id: md5cat.pm,v 1.9 2016/08/02 08:24:55 gonter Exp $
# $Id: md5cat.pm,v 1.11 2017/01/03 06:21:43 gonter Exp $
#
=head1 NAME
......@@ -353,8 +353,8 @@ sub check_new_files
close (FO);
}
push (@main::REPORT, sprintf ("checked %s: %8d (%s)", $md5cat->{'chksum_pgm'}, scalar (@tmp_2chk)));
push (@main::REPORT, sprintf ("checked openssl: %8d (%s)", $QUEUE_openssl));
push (@main::REPORT, sprintf ("checked %s: %10d (%s)", $md5cat->{'chksum_pgm'}, scalar (@tmp_2chk)));
push (@main::REPORT, sprintf ("checked openssl: %10d (%s)", $QUEUE_openssl));
(wantarray) ? @res : \@res;
}
......@@ -523,8 +523,8 @@ this may be obsolete and shold be removed
}
close (FI);
push (@main::REPORT, sprintf ("retained: %8d (%s)", $cnt_retained, $list));
push (@main::REPORT, sprintf ("dropped: %8d (%s)", $cnt_dropped, $list));
push (@main::REPORT, sprintf ("retained: %10d (%s)", $cnt_retained, $list));
push (@main::REPORT, sprintf ("dropped: %10d (%s)", $cnt_dropped, $list));
return $rc;
}
......@@ -564,7 +564,7 @@ sub digest_md5_list
}
my $md5= Digest::MD5::File::file_md5_hex ($f);
printf ("%9d %s %s\n", $st[7], $md5, $f);
printf ("%10d %s %s\n", $st[7], $md5, $f);
push (@res, [ $md5, $f, $st[7], $st[9] ]);
$cnt++;
......
......@@ -60,6 +60,7 @@ use TA::ObjReg;
# use TA::Hasher;
# use TA::Util;
use md5cat;
use Util::ts qw(ts_ISO);
my @PAR= ();
my $project;
......@@ -401,16 +402,21 @@ sub refresh_internal
# ZZZ
# update the Object registry with new items
printf ("%9d new items to be processed\n", scalar @$new_files);
my $cnt_total= scalar @$new_files;
my $cnt_done= 0;
printf ("%9d new items to be processed\n", $cnt_total);
foreach my $nf (@$new_files)
{
my ($md5, $path, $size, $mtime)= @$nf;
# print "md5=[$md5] size=[$size] path=[$path]\n";
$cnt_processed++;
$cnt_processed++; # NOTE: one counter for several processing steps??
my @upd= process_file ($md5, $path, $size);
$cnt_updated++ if (@upd);
printf ("%s done %d of %d, updated %d\n", ts_ISO(), $cnt_done, $cnt_total, $cnt_updated) if ((++$cnt_done % 100) == 0);
}
printf ("%s done %d of %d, updated %d\n", ts_ISO(), $cnt_done, $cnt_total, $cnt_updated);
# get filelist again after reintegration to find keys which are no longer in the catalog
$fl= $md5cat->{'FLIST'};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment