10

Assigning entire to a variable

view full story
linux-howto

http://www.unix.com – Hi, Need help on the below topic. I am looping finger command and trying to get each line content into a variable. Output of finger command produces more than one line and each line was multiple words. for get_line in `finger` do echo "Finger Value: ${get_line}'" done The issue is entire line is not coming into $get_line, i am getting each word from a single line into a different line. Please help me how to get entire line content into variable. Thanks in advance. Venkat (HowTos)