Getting the remote directory listing into a local file
Suppose I login with this
what next command can get the directory into a local file
or
or, can it be something like this
Should it be
"C:\Program Files (x86)\WinSCP\WinSCP.com" /command "option batch abort" "option confirm off" "open sftp://UserName:Password@site.sftpSite.com"
winscp>dir e:\data\dir.txt
winscp>dir > e:\data\dir.txt
"C:\Program Files (x86)\WinSCP\WinSCP.com" /command "option batch abort" "option confirm off" "open sftp://UserName:Password@site.sftpSite.com" "cd \OUT" "dir e:\data\dir.txt"
/console
or /command