Topic "Delete files from SFTP older than 4 days"

Author Message
capjlp
[View user's profile]

Joined: 2016-12-02
Posts: 2
Location: Kentucky, USA
Hi I am trying to script a file that task scheduler can run every day that deletes files older than 4 days old.

So that files will stay on the sftp for 4 days then fall off basically.

Can you do this with a script that can be ran through a batch file?

Thank you
martin◆
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26706
Location: Prague, Czechia
Yes, it's easy. Use rm *<4D

Some references:
https://winscp.net/eng/docs/file_mask#size_time
https://winscp.net/eng/docs/guide_automation
https://winscp.net/eng/docs/guide_schedule
Advertisements

You can post new topics in this forum

Search

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!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License