The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=65fba082f44cb9451d2b12bcd99c3287d0a47acc
commit 65fba082f44cb9451d2b12bcd99c3287d0a47acc Author: Dag-Erling Smørgrav <[email protected]> AuthorDate: 2026-06-25 03:05:36 +0000 Commit: Dag-Erling Smørgrav <[email protected]> CommitDate: 2026-06-25 03:05:36 +0000 adduser: Normalize supplemental groups Rather than insist on a space-separated list, normalize the input so that any number of spaces, commas, colons, or semicolons are accepted. Reviewed by: bcr Differential Revision: https://reviews.freebsd.org/D57774 --- usr.sbin/adduser/adduser.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/adduser/adduser.sh b/usr.sbin/adduser/adduser.sh index 94a59830c21e..96d567d133e0 100644 --- a/usr.sbin/adduser/adduser.sh +++ b/usr.sbin/adduser/adduser.sh @@ -574,13 +574,13 @@ get_groups() { if [ -z "$configflag" ]; then [ -z "$fflag" ] && echo -n "Login group is $_group. Invite $username" - [ -z "$fflag" ] && echo -n " into other (space separated) groups? [$ugroups]: " + [ -z "$fflag" ] && echo -n " into other groups? [$ugroups]: " else [ -z "$fflag" ] && echo -n "Enter additional groups [$ugroups]: " fi read _input - [ -n "$_input" ] && ugroups="$_input" + [ -n "$_input" ] && ugroups="$(echo "$_input" | tr -s ',:;' ' ')" } # get_expire_dates
