ID(1)

NAME
id - print the uid and gid

SYNOPSIS
id [-ugnr]

EXAMPLES

DESCRIPTION

Id prints the current uid and gid, both numerically and symbolically. If the effective uid and gid are different from the real ones, all of them are printed.

If the -u or -g option is specified, then id will print the effective uid or guid number, respectively, on a single line. Combined with either of those options, the -n option prints the name instead of the number, and the -r option prints the real instead of the effective uid or gid.

SEE ALSO
getuid(2), getgid(2), getgroups(2).