contents of origlist
$var1
$var4
$var3
$var2
contents of testparsher.sh
#!/bin/bash
var1="Smith^John"
var2="998877"
var3="member"
var4="12"
cat /dev/null > file.txt
filename=origlist
while read line; do
echo $line >> file.txt
done < "$filename"
the file.txt I want is:
Smith^John
12
member
998877
the file.txt I'm getting is
$var1
$var4
$var3
$var2
So what's the syntax to get the loop to see the parsed text as the preloaded variables?
Thank you so much for your time.