diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2018-11-06 01:42:13 +0100 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2018-11-06 01:42:13 +0100 |
| commit | 002e72bb172c34bb71756f9e6c23294913f1ef85 (patch) | |
| tree | ea3f3f91bb1a5219801fbf26cf5c12a3eeff1a55 /pdf_dump_first_page.sh | |
| parent | 743159991f1bcf2080693424ebe5ad7001865583 (diff) | |
maybe rm empty txts
Diffstat (limited to 'pdf_dump_first_page.sh')
| -rw-r--r-- | pdf_dump_first_page.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pdf_dump_first_page.sh b/pdf_dump_first_page.sh index ec1d3bbb..2749915d 100644 --- a/pdf_dump_first_page.sh +++ b/pdf_dump_first_page.sh @@ -7,5 +7,13 @@ for i in datasets/s2/pdf/*/*/*.pdf then pdf2txt.py -p 1 $i > $OUTPUT echo $OUTPUT + else + if [ -s $OUTPUT ] + then + echo "found $OUTPUT" + else + echo "rm empty $OUTPUT" + rm -f $OUTPUT + fi fi done |
