>>>>> "RJK" == Ronald J Kimball <[EMAIL PROTECTED]> writes:

  RJK> As Tal suggested, you should be using "or" instead.  (Putting
  RJK> parentheses around chmod's arguments would also work.)

i agree with that but the OP should also put $! in the die message so if
there is an error she can know what it is.

can you create a short runnable script which shows this problem? create
a dir or file with perms you want to change (not 0777), show the ls -l
of that, run the short script (should just be that one line, could be
perl -e) and the another ls -l showing the new or unchanged perms.

here is what it should look like:

> touch foo
> ls -l foo
-rw-r--r--   1 uri      staff           0 Aug 11 11:40 foo
> perl -e 'chmod 0777, "foo" or die "chmod failed $!"'
> ls -l foo
-rwxrwxrwx   1 uri      staff           0 Aug 11 11:40 foo*
> 

uri

-- 
Uri Guttman  ------  [EMAIL PROTECTED]  -------- http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs  ----------------------------  http://jobs.perl.org
 
_______________________________________________
Boston-pm mailing list
[email protected]
http://mail.pm.org/mailman/listinfo/boston-pm

Reply via email to