Topic "Subfolders getting deleted while using the file mask"

Author Message
[View user's profile]

Joined: 2016-10-03
Posts: 1
We are using the below script for archiving the files.

E:\app\WinSCP\WinSCP.exe /console /command "option batch on" "option confirm off" "open sftp://user:server:port" "mget -delete -filemask=<60D /Source/ Destination\" "ëxit"

It's coping and deleting the files (older than 60 days) including files under sub folders to destination but it is deleting the Sub-folders as well if they are older than 60 days.

We just want only files to be removed after successful transmission not sub-folders.

Can someone please advise what needs to be done for that.

[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24759
Location: Prague, Czechia

You can post new topics in this forum

Search Site

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