HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

groups — Print group memberships for a user. See also: `groupadd`, `groupdel`, `groupmod`. More information:

Submitted by: @import:tldr-pages··
0
Viewed 0 times
membershipscommandgroupcliprintuserforgroups

Problem

How to use the groups command: Print group memberships for a user. See also: groupadd, groupdel, groupmod. More information: <https://www.gnu.org/software/coreutils/manual/html_node/groups-invocation.html>.

Solution

groups — Print group memberships for a user. See also: groupadd, groupdel, groupmod. More information: <https://www.gnu.org/software/coreutils/manual/html_node/groups-invocation.html>.

Print group memberships for the current user:
groups


Print group memberships for a list of users:
groups {{username1 username2 ...}}

Code Snippets

Print group memberships for the current user

groups

Print group memberships for a list of users

groups {{username1 username2 ...}}

Context

tldr-pages: common/groups

Revisions (0)

No revisions yet.