Tony Esposito wrote: > > Fellow Perl neophytes ( and non-neophytes),
Hello, > I need a little clarification. I am trying to remove files that are > greater that 24 hours old. The code snippet below is in a 'while' loop that > steps through a directory, yet it seems not to work - no files are removed > no matter what their 'age' ( i.e., their creation time ). I have stepped > through the code via the Perl debugger and know the code is being executed. > > unlink $file unless -C $file < 1; > > Another question - is the creation time of a file 'updated' whenever > a 'write' to the file is performed or does the creation time remain static? > I need a way to delete files based on the file creation time and that time > needs to be static. perldoc -f -C -M Age of file in days when script started. -A Same for access time. -C Same for inode change time. In *nix files do not have a creation time. You probably want to use -M instead. John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]