chgrp [-fhv] [-R [-H | -L | -P]] group file …
chgrp
sets the group ID of file
.
-f |
group
can be a group name or group ID.
The user invoking chgrp
must belong to the group and be the owner of the file, or be the super-user.
Display the (effective, real and supplementary) group IDs the user is a member of.
> id -G 20 12 61 79 80 81 98 102 705 703 704 702 701 33 100 204 250 395 103 101 400 > id -p mgerman | sed "s/ /\n/g"|sort|column |expand #list mgerman's group names, and make it pretty_analyticsusers admin com.apple.sharepoint.group.3 _appserveradm com.apple.access_ftp com.apple.sharepoint.group.4 _appserverusr com.apple.access_remote_ae com.apple.sharepoint.group.5 _appstore com.apple.access_screensharing-disabled everyone _developer com.apple.access_ssh-disabled groups staff _lpadmin com.apple.sharepoint.group.1 localaccounts _lpoperator com.apple.sharepoint.group.2 uid mgerman
Exits
Files
/etc/group
group ID file
See chown, group, passwd, symlink, chown, ls, fts