Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #script.sh
- #!/bin/bash
- echo "starting"
- dir=$(pwd)
- count=0
- for f in *.pdf
- do
- if [ $count -eq 4 ]; then
- wait
- count=0
- fi
- ./pdfToTxt.sh $f &
- count=$((count+1))
- echo $count
- done
- echo "done"
- #pdfToTxt.sh
- #!/bin/bash
- echo "converting "$1
- gs -o /tmp/$1.tif -sDEVICE=tiffg4 -r720x720 -g6120x7920 $1 > /dev/null
- tesseract /tmp/$1.tif $1 > /dev/null
- rm /tmp/$1.tif
- echo "converted"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement