]> git.cameronkatri.com Git - pw-darwin.git/blobdiff - adduser/adduser.sh
Assume manpages are compressed with zst
[pw-darwin.git] / adduser / adduser.sh
index 8e05f33c545d021fd29e3e70ee755d6c365d74ee..b9abd81e9eca9380e63e9cdfa86d907d342cb6e8 100644 (file)
@@ -1,5 +1,7 @@
 #!/bin/sh
 #
+# SPDX-License-Identifier: BSD-2-Clause-FreeBSD
+#
 # Copyright (c) 2002-2004 Michael Telahun Makonnen. All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
@@ -488,6 +490,7 @@ get_uid() {
        _prompt=
 
        if [ -n "$uuid" ]; then
+               uuid=`get_nextuid $uuid`
                _prompt="Uid [$uuid]: "
        else
                _prompt="Uid (Leave empty for default): "
@@ -730,10 +733,10 @@ input_interactive() {
                                        trap 'stty echo; exit' 0 1 2 3 15
                                        stty -echo
                                        echo -n "Enter password: "
-                                       read -r upass
+                                       IFS= read -r upass
                                        echo''
                                        echo -n "Enter password again: "
-                                       read -r _passconfirm
+                                       IFS= read -r _passconfirm
                                        echo ''
                                        stty echo
                                        # if user entered a blank password
@@ -874,7 +877,7 @@ disableflag=
 Dflag=
 Sflag=
 readconfig="yes"
-homeprefix="/home"
+homeprefix="/var"
 randompass=
 fileline=
 savedpwtype=
@@ -894,7 +897,7 @@ if [ "$procowner" != "0" ]; then
        exit 1
 fi
 
-# Overide from our conf file
+# Override from our conf file
 # Quickly go through the commandline line to see if we should read
 # from our configuration file. The actual parsing of the commandline
 # arguments happens after we read in our configuration file (commandline
@@ -914,7 +917,7 @@ if [ -n "$readconfig" ]; then
        fi
 fi 
 
-# Proccess command-line options
+# Process command-line options
 #
 for _switch ; do
        case $_switch in