Determining the owner of a folder
Mac Dude
macbox at earthlink.net
Wed Sep 24 18:43:00 EDT 2003
I'm fairly ignorant about Unix (though learning), so I'm unable to
figure out how to tell if the current rev user has permission to open a
folder. If I understand correctly, I can get the permissions via "the
long folders", and from that I can see that, for instance, a folder
with 777 permissions can be opened by anyone, and one with 700
permissions can only be opened by the owner (correct?), but how can I
tell if the current user is indeed the owner?
The only thing that comes to mind sounds sloppy, retrieve the
specialFolderPath("desktop") and grab the userName from the returned
path, then check any generated path to see if it is in the USERS folder
and then if it is in the username's home folder or not. However, I
don't think that would cover everything. Is there a nice clean method?
This is under Mac OS X using revolution 2.1
More information about the use-livecode
mailing list