Let’s say I have the following Bash script:
while read SCRIPT_SOURCE_LINE; do echo \"$SCRIPT_SOURCE_LINE\" done
I noticed that for files
In your first example, I'm assuming you are reading from stdin. To do the same with the second code block, you just have to remove the redirection and echo $REPLY:
DONE=false until $DONE ;do read || DONE=true echo $REPLY done