Quote:
Originally Posted by bsandeep_80
Hi dennis,
#!/bin/sh
var=$(ftp www.state.il.us << EOFFile
symphems
binary
ls
quit
EOFfile
)
This gives me the required results but the results of echo $var is as below:
11:52PM 61954 help1.zip 09-02-08 10:01PM 8153 help2.zip 09-02-08 10:01PM 1890 help3.zip
The results are in a single line.
Can you please help how i can have them one fter another.
Thanks,
Sandy
|
Assuming that you have only zip files in the location:
Code:
echo $var | sed 's/zip/zip\n/g'