in reply to Re: backup script runs out of memory
in thread backup script runs out of memory

Thanks. I should have looked at the man page for tar to see if it could have used the ignorefile straight up.

I do, however, have a question about this line
if ( length( $ignorefile ) and -f $ignorefile and -r _ );
I understand the first two checks to see if the argument is specified and if that file exists. But what is the third check? I thought that -r should test if the file is readable. But what then is the _?

Replies are listed 'Best First'.
Re^3: backup script runs out of memory
by graff (Chancellor) on Aug 09, 2006 at 21:04 UTC
    But what then is the _?

    Look up "perldoc -f -X"; the underscore means "get this information from the same stat data structure that we used the last time", which saves a few ops. "-r _" assures that the file we just checked with "-f" is readable by the current user.