I am not the person you quoted, but I have a similar request. I work with image-sequences of videos, they are numbered. So if the download would happen in alphabetical order, I could already have a look/start working on the first couple of images, while the rest is still being downloaded. It would be nice to have an option to choose between server-presented-order or alphabetical.
Thank you!
WinSCP can first get the file list from remote, sort it, and then start downloading in the alphabetical order.
Why cant it do that?
That's correct. Thanks for sharing your solution.
Disregard, I figured out how to do this:
get -delete -resume -filemask=*_00*.mkv %2% %3%
get -delete -resume -filemask=*_01*.mkv %2% %3%
get -delete -resume -filemask=*_02*.mkv %2% %3%
Hi Martin, thank you for your reply. What I am trying to achieve is downloading the files in the correct order. One workaround I thought of was using multiple get commands with wild cards, to match files in the correct order (e.g. *_00*.mkv, *_01*.mkv etc)
The files I need to copy are a few levels down and the interim folders are variable. e.g.
/media/path1/variable1/variable2/20150302_003851.mkv \\172.16.1.120\path2\variable1\variable2\
I've tried using the following and a few other variations, but it does not work:
get -delete /media/path1/*/*/*_00*.mkv \\172.16.1.120\path2\
If I use the full path it works:
get -delete /media/path1/variable1/variable2/*_00*.mkv \\172.16.1.120\path2\variable1\variable2\
Is there anyway I can give wildcard for the interim folders?
As most programs, WinSCP downloads the files in the order as they are presented by the server.
Hi, I'm using Winscp to 'get -delete' all files and directories from one server and copy to another server using a batch file which uses parses parameters to a .conf file. The order in which the files are copied appears to be completely random. Typically most programs will copy in alphabetical order. How does Winscp determine the order in which to copy? Is there anyway to make Winscp copy in alphabetical order?
This is an example of the order in which winscp is copying.
20150302_123851.mkv
20150302_104348.mkv
20150302_131852.mkv
20150302_133353.mkv
20150302_102356.mkv
Here are my script files.
#batch file contents
winscp.com" /xmllog="C:\Logs\log.xml" /loglevel=0 /script=C:\WinSCP\winscp.conf /parameter 192.168.2.1 /media/path1 \\172.16.1.120\path2\
#winscp.conf contents
option batch continue
open sftp://user:pass@%1%/ -timeout=60 -rawsettings SendBuf=0
option confirm off
get -delete -resume %2%/*.* %3%
close
exit