From: epg <> Date: Sun, 25 Aug 2002 20:26:27 +0000 (+0000) Subject: (kill_spam): Display progress report since this can be a lengthy X-Git-Url: https://diplodocus.org/git/minc/commitdiff_plain/3db5b7a6f5dc200c3dad73ab857943113141f807?hp=33fe3075f50e4632f8a71854bef368889bff217f (kill_spam): Display progress report since this can be a lengthy operation with no output otherwise. --- diff --git a/minc b/minc index 4fc8582..49b9afe 100755 --- a/minc +++ b/minc @@ -391,16 +391,22 @@ sub kill_spam { my @msglist = @_; my @result; my $msg; + my $i; @result = (); + $i = 0; foreach $msg (@msglist) { + printf('%sChecking for spam... %6d/%d', + "\r", ++$i, scalar(@msglist)); if (is_spam($msg)) { + print(" SPAM\n"); store_message($msg, 'SPAM'); } else { push(@result, $msg); } } + print("\nDone: ", scalar(@result), "\n"); return @result; }