diff options
author | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2020-02-02 15:51:22 -0600 |
---|---|---|
committer | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2020-02-02 15:51:22 -0600 |
commit | 56a2be328504b9d7e49ee87279c394644f7a3009 (patch) | |
tree | c71c63336f24e665f90cbab37448a153538ce9f1 /adduser | |
parent | ae61fe98419a46847009f0153d6b2e43f5bed891 (diff) | |
download | image-56a2be328504b9d7e49ee87279c394644f7a3009.tar.gz image-56a2be328504b9d7e49ee87279c394644f7a3009.tar.bz2 image-56a2be328504b9d7e49ee87279c394644f7a3009.tar.xz image-56a2be328504b9d7e49ee87279c394644f7a3009.zip |
adelie-build-{cd,txz}: Remove vestiges of boxes past
Diffstat (limited to 'adduser')
-rwxr-xr-x | adduser | 90 |
1 files changed, 0 insertions, 90 deletions
diff --git a/adduser b/adduser deleted file mode 100755 index ba9d90a..0000000 --- a/adduser +++ /dev/null @@ -1,90 +0,0 @@ -#!/bin/sh -# adduser - BusyBox compatibility shim -# bbshim -# -# Copyright © 2017 A. Wilcox. All rights reserved. -# Licensed under the terms of the NCSA Open Source license. -# - -# The GECOS for the new user. -GECOS="Linux User,,," - -# Additional groups in which to add the new user. -MYGROUPS= - -# Path to the home directory for the new user. -HOMEDIR= - -# Don't call passwd(1) for the new user afterwards. -NOPASSWD=0 - -# The new user's shell. -MYSHELL=$SHELL - -# An alternative skeleton directory for the new user's home directory. -SKEL=/etc/skel - -# The new user is a system user. -SYSTEM=0 - -# Use this UID number for the new user. -MYUID= - - -ARG= - -while getopts h:g:s:G:SDHu:k: ARG -do - case $ARG in - h) HOMEDIR=$OPTARG ;; - g) GECOS=$OPTARG ;; - s) MYSHELL=$OPTARG ;; - G) MYGROUPS=$OPTARG ;; - S) SYSTEM=1 - MYSHELL="/bin/false";; - D) NOPASSWD=1 ;; - H) unset HOMEDIR ;; - u) MYUID=$OPTARG ;; - k) SKEL=$OPTARG ;; - :) exit 1 ;; - \?) exit 1 ;; - esac -done - -shift $(($OPTIND - 1)) - -if [ -z "$*" ]; then - echo "$0: user name is required" >&2 - exit 1 -fi - -set "$@" - - -CMDLINE="-s $MYSHELL" - -if [ -n "$MYGROUPS" ]; then - CMDLINE="$CMDLINE -g $MYGROUPS" -fi - -if [ -n "$HOMEDIR" ]; then - CMDLINE="$CMDLINE -m -d \"$HOMEDIR\" -k \"$SKEL\"" -fi - -if [ $SYSTEM -ne 0 ]; then - CMDLINE="$CMDLINE -r" -fi - -if [ -n "$MYUID" ]; then - CMDLINE="$CMDLINE -u $MYUID" -fi - -if [ -n "$2" ]; then - CMDLINE="$CMDLINE -g $2" -fi - -useradd -c "$GECOS" $CMDLINE $1 - -#if [ $NOPASSWD -eq 0 ]; then -# passwd $1 -#fi |