Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 11 Feb 2019 17:48:52 +0000 (UTC)
From:      Benedict Reuschling <bcr@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r344017 - stable/11/usr.sbin/pw
Message-ID:  <201902111748.x1BHmqht009846@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bcr (doc committer)
Date: Mon Feb 11 17:48:52 2019
New Revision: 344017
URL: https://svnweb.freebsd.org/changeset/base/344017

Log:
  MFC r343921:
  
  Add an example to pw.8 about how to add an existing user to a group.
  
  Instead of using pw to modify group membership, users often edit
  /etc/group by hand, which is discouraged.  Provide an example of
  adding a user to the wheel group, which is a common use case.
  I'm using a different user here as in the previous example as that
  deleted the user (although the examples don't necessarily have to
  be followed in order).
  
  Reviewed by:	rgrimes,0mp
  Approved by:    0mp
  Differential Revision:	https://reviews.freebsd.org/D19123

Modified:
  stable/11/usr.sbin/pw/pw.8
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/usr.sbin/pw/pw.8
==============================================================================
--- stable/11/usr.sbin/pw/pw.8	Mon Feb 11 17:47:22 2019	(r344016)
+++ stable/11/usr.sbin/pw/pw.8	Mon Feb 11 17:48:52 2019	(r344017)
@@ -24,7 +24,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd December 10, 2017
+.Dd February 8, 2019
 .Dt PW 8
 .Os
 .Sh NAME
@@ -973,6 +973,12 @@ is created if it does not already exist.
 Finally, a random password is generated and displayed:
 .Bd -literal -offset indent
 pw useradd -n gsmith -c "Glurmo Smith" -s /bin/csh -m -w random
+.Ed
+.Pp
+Add the existing user jsmith to the wheel group,
+in addition to the other groups jsmith is already a member of.
+.Bd -literal -offset indent
+pw groupmod wheel -m jsmith
 .Ed
 .Sh EXIT STATUS
 The



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201902111748.x1BHmqht009846>