Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How can I delete files at sftp older than x number of days? I'm using WinSCP client to connect to the sftp.

share|improve this question
add comment

migrated from stackoverflow.com Oct 22 '12 at 7:20

This question came from our site for professional and enthusiast programmers.

1 Answer

If you want to do this from GUI, select files to be deleted using file mask with time-constraint (*<4D for 4 days) and than just delete them.

Some references:
http://winscp.net/eng/docs/ui_select
http://winscp.net/eng/docs/file_mask

If you want to automate it, use rm command with the same mask:
http://winscp.net/eng/docs/guide_automation
http://winscp.net/eng/docs/scriptcommand_rm

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.