Sakti has asked for the wisdom of the Perl Monks concerning the following question:

This is pretty basic, but I just found by reviewing some scripts an expression that is something like:
if (! -r $out) { #do some stuff inside }
I've been trying to search what the "-r" means before an expression, any ideas?

Replies are listed 'Best First'.
Re: What does the -r do in a perl script?
by toolic (Bishop) on Jun 07, 2011 at 15:23 UTC
    From -r:
    A file test... -r File is readable by effective uid/gid.
Re: What does the -r do in a perl script?
by ikegami (Patriarch) on Jun 07, 2011 at 15:23 UTC
      Thank you both guys!!