Reading and setting file permissions programmatically

Cameron Pulsford cameron.pulsford at gmail.com
Wed Jun 17 16:35:58 EDT 2009


Sorry to flood the list but my google fu isn't up to par today I guess.
Basically, is it possible to read the permissions on one file and then set
the permissions of another file to the ones we just read? os.dup2 seemed
like it would work but I might not be using it correctly.

I know there is os.chmod, but I haven't found the equivalent to read
permissions. Preferably this would work on unix and windows too.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20090617/d8380bad/attachment.html>


More information about the Python-list mailing list