interface clean up

This commit is contained in:
Bryan Bailey
2019-11-07 18:45:48 -05:00
parent bbe2d7a8f7
commit c65cce4545
6 changed files with 223 additions and 17 deletions

View File

@@ -10,6 +10,7 @@ def create_comic_archive(title, folder):
output = shutil.make_archive(title, 'zip', folder)
os.rename(output, os.path.join(folder, title +'.cbr'))
print('Performing folder cleanup...')
ignore = ('.cbr', '000.jpg')
for img in os.listdir(folder):
if not img.endswith('.cbr'):
if not img.endswith(ignore):
os.remove(os.path.join(folder, img))