NaviServer Programmable Web Server

ns_purgefiles(n)

NaviServer Built-in Commands – 5.0.0a


[ Main Table Of Contents | Table Of Contents | Keyword Index ]

Name

ns_purgefiles - Purge files by date, keeping max files

Table Of Contents

Synopsis

Description

Purge files by date, keeping max files.

COMMANDS

ns_purgefiles path maxbackups

The parameter path denotes the base of the files to delete. the files are matched internally with the trailing wildcard character *. The files are then sorted by their modification time and the newest number of maxbackups files are kept.

The function ns_rollfile is similar but rolls the file by appending a numeric suffix.

See Also

ns_rollfile, nsd

Keywords

NaviServer, backup, global built-in, logging