File::PurgeFile
Description

Purge single file or all files in a directory-tree. A file will be purged if the file is older then the specified number of days.

You can configure if you want to use the creation- or modification date of the file to determine if the file needs to be purged.

Optionally empty directories can also be purged.
Optionally the purged files can be moved to another directory in which case they are not deleted.

Options
Single File

Only purge the specified file.

Directory Tree

Purge all files in the specified directory-tree.

File / Directory
The file that must be purged (Single File), or directory (Directory Tree).
Include Subdirectories

Include files in subdirectories.

Include Hidden Files

Include hidden files.

Remove Empty Directories

Remove empty directories.

Purge Files Older Than

The number of days the file must be old before it will be deleted.

Use Creation/Modification Date

Determines if the file's creation- or modification date should be used to decide if the file must be purged.

Keep number of files

Purges all files and leaves the specified number of files. The oldest files will be removed.

Move Purged Files
If enabled, the purged files will not be deleted but moved to the "Output Directory". The directory-tree of the sourcefile will be replicated in "Output Directory".