Script put -latest upload only the last single file modified

Advertisement

MicheleOSM3@gmail.com
Joined:
Posts:
1

Script put -latest upload only the last single file modified

I don't understand how the -latest option works.
I have 2 files in the local folder and I want to upload them, both files have just been modified in the local folder, but only the last single file modified in the local folder is uploaded, why?

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,034
Location:
Prague, Czechia

Re: script put -latest upload only the last single file modified

Because, that's what the "latest" means, doesn't it?
See https://winscp.net/eng/docs/scriptcommand_put#latest
WinSCP cannot do what you wanted it to do. WinSCP does not keep any database of your files to be able to tell that you have two new files.
You would have to code such "database" yourself.
We have an example for download, upload would be pretty similar:
Remember already downloaded files so they are not downloaded again
For other less complicated options, see:
How do I transfer new/modified files only?
Though if you have just two files in the folder, and you want to upload all, just upload all of them.

Reply with quote

Advertisement

You can post new topics in this forum