From 298a7291ead9e57c026413899d97948d2bc36778 Mon Sep 17 00:00:00 2001 From: Patrick Jentsch Date: Wed, 10 Jun 2020 15:04:57 +0200 Subject: [PATCH] don't remove input files --- file-setup | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/file-setup b/file-setup index 00975f9..ce58560 100755 --- a/file-setup +++ b/file-setup @@ -45,9 +45,6 @@ def merge_images(input_dir, output_dir, output_file_base, zip): + '-path "{o}" @"{i}"/file_list.txt').format(i=input_dir, o=tmp_dir) subprocess.run(cmd, shell=True) - # remove image files - cmd = 'xargs rm <{i}/file_list.txt'.format(i=input_dir) - subprocess.run(cmd, shell=True) # remove file list cmd = 'rm "{i}"/file_list.txt'.format(i=input_dir) subprocess.run(cmd, shell=True) @@ -58,7 +55,7 @@ def merge_images(input_dir, output_dir, output_file_base, zip): ofb=output_file_base) subprocess.run(cmd, shell=True) # remove single pdf files - cmd = 'rm -fr {i}/tmp'.format(i=input_dir) + cmd = 'rm -r {tmp_i}'.format(tmp_i=tmp_dir) subprocess.run(cmd, shell=True) # zip stuff if zip is not None: