[Wellington-pm] File tests

Cliff Pratt enkidu at cliffp.com
Mon Nov 3 01:47:47 PST 2008

If $dir = Y is a directory and exists then the following snippet prints 
nothing  (as desired and expected). If $dir = Y/ZZ exists and is a link 
I get 'File or directory "Y/ZZ" does not exist'. I'd rather it prints 

Obviously I'm missing something. But what?



if ( ! -e "$dir" )
    $self->{error_msg} = "File or directory \"$dir\" does not exist." ;
    $self->{error} = 'true' ;
    print "$self->{error_msg}\n" ;
    return 1 ;

More information about the Wellington-pm mailing list