Chmod to a group only
jonas.esp at googlemail.com
Mon Dec 1 21:10:11 CET 2008
On 1 dic, 18:17, Kless <jonas.... at googlemail.com> wrote:
> How to chmod a file to: o-rwx ? (to change only the others mode)
> os.chmod(fname, )
> I was reading this , but the truth is that anything as 'S_IRUSR'
> doesn't help enought.
I have tried:
mode = os.stat(fname).st_mode
os.chmod(fname, mode | stat.S_IRWXO) => Changes to o+rwx
and if is used:
os.chmod(fname, mode & stat.S_IRWXO) => Delete all modes
Any help? please
More information about the Python-list