How can I read from variable with while read line
?
For example:
the_list=$(..code..)
while read line
do
echo $line
done < $the_list
using the code above gives me error:
./copy.sh: line 25: $the_list: ambiguous redirect
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…