I am attempting to capture only the first return from a multiple line return into a variable.
Command results:
Code:
TVE-2001-1111
TVE-2001-1111
TVE-2001-1111
TVE-2001-1111
Variable results after capture:
Code:
TVE-2001-1111 TVE-2001-1111 TVE-2001-1111 TVE-2001-1111
What I need:
I've tried using awk on the variable in the script by
Code:
cat $VarName | awk '{$print %1}'
But alas it's not that easy. I'm sure there is something simple I am missing. Any help would be much appreciated.