Don't waste your time guessing. Perl provides the answer:
$ perl -e 'if (-f "foobarama") { print "file exists" } elsif ($!) { pr +int "$!\n" }' No such file or directory $ perl -e 'if (-f "/root/foobarama") { print "file exists" } elsif ($! +) { print "$!\n" }' Permission denied
In reply to Re: From chat to here :) chdir() and test -f issues.
by converter
in thread From chat to here :) chdir() and test -f issues.
by snafu
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |