Hello all,
I want to use sed to append a variable stored in $i, how do i do that?
$i contains a path to a directory and i want to append it before the result i get from awk statement, before affecting awk results.
rite now out put i get from code below is:-
The path is: /net/icebox/vol/local_images/spins/7.1/CQ/7.1.D081110/
basement.sun5
msgcat.JPN.sun5
perl.sun5
CMServer.CQ.sun5
Output desired:-
The path is: /net/icebox/vol/local_images/spins/7.1/CQ/7.1.D081110/
basement.sun5 /net/icebox/vol/local_images/spins/7.1/CQ/7.1.D081110/
msgcat.JPN.sun5 /net/icebox/vol/local_images/spins/7.1/CQ/7.1.D081110/
perl.sun5 /net/icebox/vol/local_images/spins/7.1/CQ/7.1.D081110/
CMServer.CQ.sun5 /net/icebox/vol/local_images/spins/7.1/CQ/7.1.D081110/
check_sun() {
for i in $SUN_PLATFORM
do
$ECHO "The path is: " $i
$LS $i | $GREP .su | $AWK -F"_" '{print $1}'
done
}
Thanks
Adsi