I am very new to Linux shell scripting and would be grateful if someone could help me with this
I have the following so far
-----------------------------------------
#!/bin/bash
set -e
f="$1"
out="$2"
for f; do
if [ -e *.tiff ]
then
mv $f ${f%.tiff}.pdf
#I want to rename the file if it has tiff extension to pdf. which the above command I think does.
#However I want to move it to /tmp folder.
#I then want that file name to be next to "-if" in the below command
/opt/ocr -if ${f%.tiff}.pdf -of ${out}
rm ${f%.tiff}.pdf
fi
------------------------------------------
many thanks for looking.