aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/pw/pw.8
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/pw/pw.8')
-rw-r--r--usr.sbin/pw/pw.825
1 files changed, 23 insertions, 2 deletions
diff --git a/usr.sbin/pw/pw.8 b/usr.sbin/pw/pw.8
index c72623ee05b3..f6d9ebca6308 100644
--- a/usr.sbin/pw/pw.8
+++ b/usr.sbin/pw/pw.8
@@ -22,7 +22,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.Dd July 29, 2024
+.Dd August 19, 2025
.Dt PW 8
.Os
.Sh NAME
@@ -30,6 +30,7 @@
.Nd create, remove, modify & display system users and groups
.Sh SYNOPSIS
.Nm
+.Op Fl M Ar metalog
.Op Fl R Ar rootdir
.Op Fl V Ar etcdir
.Cm useradd
@@ -191,7 +192,12 @@ utility handles updating the
.Xr master.passwd 5 ,
.Xr group 5
and the secure and insecure
-password database files, and must be run as root.
+password database files, and must be run as root
+.Po except when using
+.Fl R
+or
+.Fl V
+.Pc .
.Pp
The first one or two keywords provided to
.Nm
@@ -459,6 +465,21 @@ option, bearing the name of the new account.
This can be overridden by the
.Fl d
option on the command line, if desired.
+.It Fl M Ar metalog
+Specify a path to a
+.Xr mtree 5
+metalog file.
+.Nm
+will add entries for all files added to a user's home directory.
+This is useful when building images as a non-root user, as the
+metalog can be used as input to
+.Xr tar 1
+or
+.Xr makefs 8 .
+Note that this option must precede the
+.Ql useradd
+string on the command line, otherwise it will be interpreted as the mode
+option.
.It Fl M Ar mode
Create the user's home directory with the specified
.Ar mode ,