Update ocr command

This commit is contained in:
Rezart Qelibari
2022-04-19 06:26:37 +02:00
parent 3836b8195c
commit 5e65a5cd2c

13
bin/ocr
View File

@@ -1,9 +1,6 @@
#!/bin/sh #!/bin/zsh
for pdf in ./*.pdf; do mkdir -p OCRed || exit
filename="`basename "${pdf}"`"; for pdf in *.pdf; do
path="`dirname "${pdf}"`"; print -- "OCRing ${pdf}"
mkdir -p OCRed; ocrmypdf -l deu ${pdf} ./OCRed/${pdf};
printf 'OCRing %s' "${pdf}";
ocrmypdf -l deu "${pdf}" "${path}/OCRed/${filename}";
printf '...done\n';
done done