diff --git a/scripts/pdf_unlock.py b/scripts/pdf_unlock.py index 4d9d9e7..9f77fb0 100644 --- a/scripts/pdf_unlock.py +++ b/scripts/pdf_unlock.py @@ -39,10 +39,10 @@ __email__ = "d.howe@wrl.unsw.edu.au" import os import glob +import shutil import argparse import subprocess -import shutil - +from tqdm import tqdm def pdf_unlock(pdf_file, overwrite=False): # Create suffix for unlocked pdfs @@ -101,7 +101,10 @@ def main(): pdf_files = glob.glob(glob_str, recursive=args.recursive) - for pdf_file in pdf_files: + pbar = tqdm(pdf_files) + for pdf_file in pbar: + pdf_file_shortname = os.path.split(pdf_file)[1] + pbar.set_description('Processing {}'.format(pdf_file_shortname)) pdf_unlock(pdf_file, overwrite=args.overwrite)