Menu

Home

Usage (1)
Richard Farthing

Usage is simple - defaults are shown in brackets
This new version has been updated to add the -l (hard limit) option
and improve message formatting

FTPprune <options> -s <server URL>

Options:
-d debug (don't delete, just show file listing & what would happen)
-f <directory (.)>
-a <minimum file age in days before deletion (31)>
-m <max qty of Mbytes to keep on server in (100)>
-u <username (anonymous)>
-p <password (FTPprune@)>
-i <ignore extension(s)> ignore files of these type(s), comma separated
-b Mbyte = 1024k instead of 1000k
-k sort key is size, instead of default: age
-l <hard limit> in Mbytes, ignoring age, soft limit

Note that you will need these basic Perl modules from CPAN to make it work

Getopt::Std
Net::FTP
File::Listing
FileHandle
POSIX
Number::Bytes::Human
Time::Duration

Enjoy!