summaryrefslogtreecommitdiff
path: root/source/a/shadow/adduser
diff options
context:
space:
mode:
authorPatrick J Volkerding <volkerdi@slackware.com>2010-05-19 08:58:23 +0000
committerEric Hameleers <alien@slackware.com>2018-05-31 22:43:05 +0200
commitb76270bf9e6dd375e495fec92140a79a79415d27 (patch)
tree3dbed78b2279bf9f14207a16dc634b90995cbd40 /source/a/shadow/adduser
parent5a12e7c134274dba706667107d10d231517d3e05 (diff)
downloadcurrent-b76270bf9e6dd375e495fec92140a79a79415d27.tar.gz
Slackware 13.1slackware-13.1
Wed May 19 08:58:23 UTC 2010 Slackware 13.1 x86_64 stable is released! Lots of thanks are due -- see the RELEASE_NOTES and the rest of the ChangeLog for credits. The ISOs are on their way to replication, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. We are taking pre-orders now at store.slackware.com, and offering a discount if you sign up for a subscription. Consider picking up a copy to help support the project. Thanks again to the Slackware community for testing, contributing, and generally holding us to a high level of quality. :-) Enjoy!
Diffstat (limited to 'source/a/shadow/adduser')
-rw-r--r--source/a/shadow/adduser13
1 files changed, 8 insertions, 5 deletions
diff --git a/source/a/shadow/adduser b/source/a/shadow/adduser
index 02385e33..038a0a94 100644
--- a/source/a/shadow/adduser
+++ b/source/a/shadow/adduser
@@ -1,8 +1,8 @@
#!/bin/bash
#
# Copyright 1995 Hrvoje Dogan, Croatia.
-# Copyright 2002, 2003, 2004, 2008, 2009 Stuart Winter, Surrey, England, UK.
-# Copyright 2004, 2008, 2009 Slackware Linux, Inc., Concord, CA, USA
+# Copyright 2002-2004, 2008, 2009, 2010 Stuart Winter, Surrey, England, UK.
+# Copyright 2004, 2008-2010 Slackware Linux, Inc., Concord, CA, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -29,12 +29,15 @@
# Author : Stuart Winter <mozes@slackware.com>
# Based on the original Slackware adduser by Hrvoje Dogan
# with modifications by Patrick Volkerding
-# Version: 1.12
+# Version: 1.13
##########################################################################
# Usage..: adduser [<new_user_name>]
##########################################################################
# History #
###########
+# v1.13 - 13/01/10
+# * Fix bug that removed underscore characters from group names.
+# Thanks to mRgOBLIN for the report and Jim Hawkins for the fix. <sw>
# v1.12 - 21/07/09
# * Adjusted the search of /etc/passwd to exclude the NIS inclusion
# string. Thanks to Dominik L. Borkowski.
@@ -282,8 +285,8 @@ while [ ! -z "$needinput" ]; do
history -c
history -s "$AGID"
echo "Press ENTER to continue without adding any additional groups"
- echo "Or press the UP arrow to add/select/edit additional groups"
- AGID="$(get_input ": " | tr -d '[:punct:]' | tr -s ' ' | sed 's?^ $??g' )"
+ echo "Or press the UP arrow key to add/select/edit additional groups"
+ AGID="$(get_input ": " | sed 's/[^A-Za-z0-9 _]//g;s/ */ /g;s/^ $//g' )"
if [ ! -z "$AGID" ]; then
check_group "$AGID" # check all groups at once (treated as N # of params)
if [ $? -gt 0 ]; then