Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/who Sort options.



details:   https://anonhg.NetBSD.org/src/rev/7d1c456ba80e
branches:  trunk
changeset: 571406:7d1c456ba80e
user:      peter <peter%NetBSD.org@localhost>
date:      Mon Nov 22 17:20:02 2004 +0000

description:
Sort options.

ok wiz@

diffstat:

 usr.bin/who/who.1 |   8 ++++----
 usr.bin/who/who.c |  14 +++++++-------
 2 files changed, 11 insertions(+), 11 deletions(-)

diffs (86 lines):

diff -r d7e110455249 -r 7d1c456ba80e usr.bin/who/who.1
--- a/usr.bin/who/who.1 Mon Nov 22 17:17:24 2004 +0000
+++ b/usr.bin/who/who.1 Mon Nov 22 17:20:02 2004 +0000
@@ -1,4 +1,4 @@
-.\"    $NetBSD: who.1,v 1.14 2003/08/07 11:17:18 agc Exp $
+.\"    $NetBSD: who.1,v 1.15 2004/11/22 17:20:02 peter Exp $
 .\"
 .\" Copyright (c) 1986, 1991, 1993
 .\"    The Regents of the University of California.  All rights reserved.
@@ -37,7 +37,7 @@
 .Nd display who is logged in
 .Sh SYNOPSIS
 .Nm
-.Op Fl mTuH
+.Op Fl HmTu
 .Op Ar file
 .Nm
 .Ar am i
@@ -51,6 +51,8 @@
 Available options:
 .Pp
 .Bl -tag -width file
+.It Fl H
+Write column headings above the regular output.
 .It Fl m
 Only print information about the current terminal.
 This is the
@@ -70,8 +72,6 @@
 if a bad line is encountered.
 .It Fl u
 Print the idle time for each user.
-.It Fl H
-Write column headings above the regular output.
 .It Ar \&am I
 Returns the invoker's real user name.
 .It Ar file
diff -r d7e110455249 -r 7d1c456ba80e usr.bin/who/who.c
--- a/usr.bin/who/who.c Mon Nov 22 17:17:24 2004 +0000
+++ b/usr.bin/who/who.c Mon Nov 22 17:20:02 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: who.c,v 1.13 2004/01/05 23:23:37 jmmv Exp $    */
+/*     $NetBSD: who.c,v 1.14 2004/11/22 17:20:02 peter Exp $   */
 
 /*
  * Copyright (c) 1989, 1993
@@ -43,7 +43,7 @@
 #if 0
 static char sccsid[] = "@(#)who.c      8.1 (Berkeley) 6/6/93";
 #endif
-__RCSID("$NetBSD: who.c,v 1.13 2004/01/05 23:23:37 jmmv Exp $");
+__RCSID("$NetBSD: who.c,v 1.14 2004/11/22 17:20:02 peter Exp $");
 #endif /* not lint */
 
 #include <sys/types.h>
@@ -79,8 +79,11 @@
        setlocale(LC_ALL, "");
 
        only_current_term = show_term = show_idle = show_labels = 0;
-       while ((c = getopt(argc, argv, "mTuH")) != -1) {
+       while ((c = getopt(argc, argv, "HmTu")) != -1) {
                switch (c) {
+               case 'H':
+                       show_labels = 1;
+                       break;
                case 'm':
                        only_current_term = 1;
                        break;
@@ -90,9 +93,6 @@
                case 'u':
                        show_idle = 1;
                        break;
-               case 'H':
-                       show_labels = 1;
-                       break;
                default:
                        usage();
                        /* NOTREACHED */
@@ -246,7 +246,7 @@
 static void
 usage()
 {
-       (void)fprintf(stderr, "usage: %s [-mTuH] [ file ]\n       %s am i\n",
+       (void)fprintf(stderr, "usage: %s [-HmTu] [file]\n       %s am i\n",
            getprogname(), getprogname());
        exit(1);
 }



Home | Main Index | Thread Index | Old Index