in reply to How to identify a file is in readonly mode

AFAIR, open FILE, ">$some_file" will fail if some other process already has the file open for writing, thus you could eval the call (to open) and proceed based on the caught exception - if any.

A user level that continues to overstate my experience :-))

Replies are listed 'Best First'.
Re^2: How to identify a file is in readonly mode
by kulls (Hermit) on Jul 18, 2009 at 06:00 UTC
    Hi,
    You can refer this Node in the Q & A section .
    Raja
      Hmmm, not quite.

      -w tests to see if the script is capable of writing (to) the file i.e. using the statically defined permissions on the file, not dynamically i.e. run-time determination, as required by the OP.

      A user level that continues to overstate my experience :-))