Current File : //usr/man/man1/groups.1
'\" te
.\"  Copyright 1989 AT&T  Copyright (c) 1992, Sun Microsystems, Inc.  All Rights Reserved
.TH groups 1 "14 Sep 1992" "SunOS 5.11" "User Commands"
.SH NAME
groups \- print group membership of user
.SH SYNOPSIS
.LP
.nf
\fBgroups\fR [\fIuser\fR]...
.fi

.SH DESCRIPTION
.sp
.LP
The command \fBgroups\fR prints on standard output the groups to which you or the optionally specified user belong. Each user belongs to a group specified in  \fB/etc/passwd\fR and possibly to other groups as specified in  \fB/etc/group\fR. Note that  \fB/etc/passwd\fR specifies the numerical \fBID\fR (\fBgid\fR) of the group. The \fBgroups\fR command converts \fBgid\fR to the group name in the output.
.SH EXAMPLES
.sp
.LP
The output takes the following form:
.sp
.in +2
.nf
example% groups tester01 tester02
tester01 : staff
tester02 : staff
example%
.fi
.in -2
.sp

.SH FILES
.sp
.ne 2
.mk
.na
\fB\fB/etc/passwd\fR\fR
.ad
.RS 15n
.rt  

.RE

.sp
.ne 2
.mk
.na
\fB\fB/etc/group\fR\fR
.ad
.RS 15n
.rt  

.RE

.SH ATTRIBUTES
.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp

.sp
.TS
tab() box;
cw(2.75i) |cw(2.75i) 
lw(2.75i) |lw(2.75i) 
.
ATTRIBUTE TYPEATTRIBUTE VALUE
_
Availabilitysystem/core-os
.TE

.SH SEE ALSO
.sp
.LP
\fBgroup\fR(4), \fBpasswd\fR(4), \fBattributes\fR(5)