I\'m running this at a terminal on Ubuntu 11.4.
Say I execute a bash script and the output is:
Test1: Some text... Test2: Some text... Test3: Some te
So you want
output=$(command) while read -r line; do process "$line" done <<< "$output"
See "Here strings" in the Bash manual.
or process substitution
while read -r line; do process "$line" done < <(command)