From d8c0c37506f6bb1e3c83540e56b6cbb4a1a3ca4c Mon Sep 17 00:00:00 2001 From: Greg Gauthier Date: Thu, 22 Oct 2020 00:14:51 +0100 Subject: [PATCH] Add option to dump the email list to the console --- email_pruner.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/email_pruner.py b/email_pruner.py index 475adff..3731d8d 100644 --- a/email_pruner.py +++ b/email_pruner.py @@ -50,6 +50,8 @@ if __name__ == "__main__": parser = ap() parser.add_argument('-e', '--emails', type=int, default=1000, metavar="emails", help='The number of emails to generate (default=1000)', required=False) + parser.add_argument('-d', '--dump', action="store_true", + help='Dump the email list to the console (Default=no)', required=False) args = parser.parse_args() email_count = args.emails @@ -62,7 +64,8 @@ if __name__ == "__main__": start = reset_stopwatch() list_with_dups = spawn(email_count) print(f"GENERATED COMPLETE LIST WITH DUPLICATES: (count = {len(list_with_dups)})") - # [print(i) for i in list_with_dups] + if args.dump: + [print(i) for i in list_with_dups] t1 = get_elapsed(start) print("Elapsed Time: ", t1) @@ -76,7 +79,8 @@ if __name__ == "__main__": start = reset_stopwatch() dup_list, orig_list = dups(list_with_dups) print(f"IDENTIFIED DUPLICATES IN COMPLETE LIST: (count = {len(dup_list)})") - # [print(i) for i in dup_list] + if args.dump: + [print(i) for i in dup_list] t2 = get_elapsed(start) print("Elapsed time: ", t2)