Search Results

Search: Posts Made By: debojyoty
18,706
Posted By debojyoty
for loop not working - syntax error at line 6: `end of file' unexpected
I have a file called test.dat which contains

a b

I have written a shell script called test.sh

for i in `cat test.dat`
do
echo $i
done

When i run this script using

sh test.sh

I...
Showing results 1 to 1 of 1

 
All times are GMT -4. The time now is 05:16 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy