user.info: Get unix user information

Description Usage Arguments Details Value Author(s) Examples

Description

user.info queries the user database to obtain information about a list of users.

Usage

1
user.info(users = NULL)

Arguments

users

a character string of user names, numeric vectors of user IDs or NULL to obtain information about the current user

Details

user.info queries the user database to find the specified users. Each element of users will result in one row in the resulting data frame. If the user cannot be found, all entries in the row will be NA.

The database implementation is system-specific. It is not limited to the legacy /etc/passwd but insead uses getpw* system calls which may also query NIS, DomainServices, LDAP and other sources as configured in the system.

Value

data frame with users as row names and the columns name, uid, gid, realname, home and shell. Columns uid and gid are integer vectors, all others are character vectors.

Author(s)

Simon Urbanek

Examples

1
2
3
user.info()
user.info(c("root", "admin", "daemon"))
user.info(1:10)

s-u/unixtools documentation built on May 28, 2019, 10:49 a.m.