UID/GID in python 
Author Message
 UID/GID in python

What is the best way to get the uid.gid of a file in python?

is there someting that when you do like info(filename) returns the
gid,uid, file size times etc?



Mon, 28 Jul 2003 04:58:56 GMT  
 UID/GID in python


Quote:
>What is the best way to get the uid.gid of a file in python?

os.stat("foo")[stat.ST_UID]

and similarly with stat.ST_GID

Quote:
>is there someting that when you do like info(filename) returns the
>gid,uid, file size times etc?

os.stat() returns the data as a tuple and the stat module has symbolic
names for the items in the tuple.

Regards,
Matt



Mon, 28 Jul 2003 05:11:05 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. BUG: TCL uses real rather than effictive UID/GID

2. BUG: TCL uses real rather than effictive UID/GID

3. os.setpgid(pid, gid) problems

4. how to get gid of W32-Cervivec-A ????????????

5. How to determine UID of OE caller?

6. Eruby with different uid

7. Running CGIs under my uid - going slowly insane.

8. How can I use UID command in IMAPLIB?

9. cgi use root uid

10. Set UID scripts?

11. A uid merger

12. getting username from uid

 

 
Powered by phpBB® Forum Software