I want to execute some commands using the find -exec option, but I'm not sure what' wrong with this code. Currently, it's only processing the first find result, then getting stuck. I'm using bash in OS X.
read -e DIRECTORY
find $DIRECTORY -type f -name '*.mov' -exec sh -c '
file="$0"
echo "Processing $file ..."
modmovie -notrack "Timecode Track" $file -save-in-place
read line </dev/tty
' {} \;
Best Answer
I came up with this example and as others have said in the comments it's the
read line </dev/tty
that's causing it to wait for user input.My script's output