Code:
OUT="$(ftp -n $REMOTESERVER 2>&1 <<FTP
quote USER $LOGIN
quote PASS $PASSWORD
nlist $REMOTEPATH
bye
FTP
)"
echo $OUT
the output becomes something like
Code:
.
..
file1.ext
file2.ext
file3.ext
I dont know why it skips lines, but when I try to replace the lines with sed, \r or \n, it doesnt make any difference, has anyone encountered this problem before?
Thanks,
Ted