On 22/10/15 15:03, Gonçalo Paiva wrote:
> Salutations,
> 
> This is not as much a bug report but more a feature suggestion.
> In the *users* command I propose that the users has an option (since I don't 
> see one in --help)
> that allows to see users without repetition and all *users*.
> For example I have two users A and B.
> When in A session since (I assume) A is in several groups it appears:
> A A A A
> I suggest a command line option to either show the group

$ who

> or the output A.

$ who -u | cut -f1 -d ' ' | sort -u
$ users | tr ' ' '\n' | sort -u

> Also A and B should be an idea for some root option maybe!?

$ getent passwd | cut -f1 -d:


I think the required functionality exists elsewhere.
How about we just reference the appropriate utils
in the man page, as done in the attached?

cheers,
Pádraig.
From 78f890ce9f624e98bf06d948b229e90b17001925 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?P=C3=A1draig=20Brady?= <[email protected]>
Date: Thu, 22 Oct 2015 16:48:32 +0100
Subject: [PATCH] doc: reference related commands from users(1) and groups(1)

* man/users.x: See also getent, who
* man/groups.x: See also getent
---
 man/groups.x | 2 ++
 man/users.x  | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/man/groups.x b/man/groups.x
index 1e42fed..fad6845 100644
--- a/man/groups.x
+++ b/man/groups.x
@@ -2,3 +2,5 @@
 groups \- print the groups a user is in
 [DESCRIPTION]
 .\" Add any additional description here
+[SEE ALSO]
+getent(1)
diff --git a/man/users.x b/man/users.x
index ca0f9ca..d15001e 100644
--- a/man/users.x
+++ b/man/users.x
@@ -2,3 +2,5 @@
 users \- print the user names of users currently logged in to the current host
 [DESCRIPTION]
 .\" Add any additional description here
+[SEE ALSO]
+getent(1), who(1)
-- 
2.5.0

Reply via email to