More advanced FTP
With FTP there is no standard syntax for the directory output that is returned
for this sort of command that uses the standard FTP command . The
listing is usually humanly readable and perfectly understandable but you will
see that different servers will return the listing in slightly different ways.
One way to get just a listing of all the names in a directory and thus to avoid
the special formatting of the regular directory listings is to tell curl to--list-only
(or just ). curl then issues the NLST
FTP command instead:
NLST has its own quirks though, as some FTP servers list only actual files
in their response to NLST; they do not include directories and symbolic links!
Like:
or to use the local file name as the remote name:
curl also supports globbing in the -T argument so you
can opt to easily upload a range or a series of files:
curl -T '{Huey,Dewey,Louie}.jpg' ftp://ftp.example.com/nephews/
TBD
TBD
TBD