summaryrefslogtreecommitdiffstats
path: root/usr.bin/who/who.1
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2002-05-09 23:04:40 +0000
committertjr <tjr@FreeBSD.org>2002-05-09 23:04:40 +0000
commit1894db5ac7af64acc77acfbbc7b98c819dd70e22 (patch)
treee8314d1120a02aeff9fe6adf8d6111767126f210 /usr.bin/who/who.1
parentdc4e1bdffacc666da76301235b153d0c63a115f0 (diff)
downloadFreeBSD-src-1894db5ac7af64acc77acfbbc7b98c819dd70e22.zip
FreeBSD-src-1894db5ac7af64acc77acfbbc7b98c819dd70e22.tar.gz
Reimplement the who(1) utility to add some features required by SUSv3:
-H option (show column headings), -T (show mesg(1) state), -m (same as "am I"), -u (show idle time), -q (quick mode; list names in columns). PR: 36128 Reviewed by: mike
Diffstat (limited to 'usr.bin/who/who.1')
-rw-r--r--usr.bin/who/who.165
1 files changed, 50 insertions, 15 deletions
diff --git a/usr.bin/who/who.1 b/usr.bin/who/who.1
index 5abded5..f656915 100644
--- a/usr.bin/who/who.1
+++ b/usr.bin/who/who.1
@@ -32,31 +32,60 @@
.\" @(#)who.1 8.2 (Berkeley) 12/30/93
.\" $FreeBSD$
.\"
-.Dd December 30, 1993
+.Dd May 8, 2002
.Dt WHO 1
.Os
.Sh NAME
.Nm who
-.Nd display who is logged in
+.Nd display who is on the system
.Sh SYNOPSIS
.Nm
-.Ar am I
-.Nm
+.Op Fl HmqsTu
+.Op Cm am I
.Op Ar file
.Sh DESCRIPTION
The
.Nm
-utility displays
-a list of all users currently logged on, showing for each user
-the login name,
-tty name, the date and time of login, and hostname if not local.
+utility displays information about currently logged in users.
+By default, this includes the login name, tty name, date and time of login and
+remote hostname if not local.
.Pp
-Available options:
+The options are as follows:
+.Bl -tag -width indent
+.It Fl H
+Write column headings above the output.
+.It Fl m
+Show information about the terminal attached to standard input only.
+.It Fl q
+.Dq Quick mode Ns :
+List the names and number of logged in users in columns.
+All other command line options are ignored.
+.It Fl s
+Show the name, line and time fields only.
+This is the default.
+.It Fl T
+Indicate whether each user is accepting messages.
+One of the following characters is written:
+.Bl -tag -width x -compact
+.It +
+User is accepting messages.
+.It \&-
+User is not accepting messages.
+.It ?
+An error occurred.
+.El
+.It Fl u
+Show idle time for each user in hours and minutes as
+.Ql hh:mm ,
+.Ql \&.
+if the user has been idle less that a minute and
+.Ql old
+if the user has been idle more than 24 hours.
+.It Cm am I
+Equivalent to
+.Fl m .
+.El
.Pp
-.Bl -tag -width file
-.It Ar \&am I
-Returns the invoker's real user name.
-.It Ar file
By default,
.Nm
gathers information from the file
@@ -80,7 +109,6 @@ since
.Pa wtmp
was last truncated or
created.
-.El
.Pp
If
.Pa /var/log/wtmp
@@ -95,11 +123,18 @@ special characters, see
.It Pa /var/log/wtmp
.It Pa /var/log/wtmp.[0-6]
.El
+.Sh DIAGNOSTICS
+.Ex -std
.Sh SEE ALSO
.Xr last 1 ,
.Xr users 1 ,
-.Xr getuid 2 ,
+.Xr w 1 ,
.Xr utmp 5
+.Sh STANDARDS
+The
+.Nm
+utility conforms to
+.St -p1003.1-2001 .
.Sh HISTORY
A
.Nm
OpenPOWER on IntegriCloud