Setting file permissions |
|
To change a file's permissions to a specific value, use this command:
% chmod who=value file...
where who specifies the type of user that these permissions apply to:
u to change the owner's
(``user's'') permissions;
g to change group permissions;
o to change world
(``other'') permissions; or
a to change all permissions:
owner, group and world.
r for read permission;
w for write permission; and
x for execute permission.
For example:
foo so only the user can read and
write it:
% chmod u=rw foo
bar so anyone can read it, but no one
can write or execute it:
% chmod a=r bar