bash call command with each line code example
Example: how to perform an action for each line in bash
while read line
do
echo $line
// or some_function "$line"
done < testfile.txt
while read line
do
echo $line
// or some_function "$line"
done < testfile.txt