Topic "Upload file and delete local file"

Author Message
[View user's profile]

Joined: 2013-02-17
Posts: 2
Location: Singapore

I have spend the past 20 hours trying to figure this out. I have made the Sync script and is working. Soon, i realize it's not really what i wanted.

My goal is to upload all files found in c:\sync\ (there will be alot of sub folders inside) and delete from local files.

So, my sync script has successfully upload all the files inisde (and -criteria=size so that incase the file fails to upload, it will reupload)

But it does not delete the source files after uploading. I know the PUT command has a delete option. I could use PUT -delete *.* But the problem is that the sub directories and folders are not automatically created (correct me if i am wrong).

So am i right to say, the PUT command cannot automatically create the sub folders and upload *.*? I need the -delete command. There is no Move or Sync -delete Sad

Thanks for all the help Smile
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26911
Location: Prague, Czechia
Using "put" is definitelly a way to go. Yes, it will automatically create the non-existing subfolders.

See also
Martin Prikryl

You can post new topics in this forum


What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!


About donations

$9   $19   $49   $99

About donations


WinSCP Privacy Policy

WinSCP License