summaryrefslogtreecommitdiff
path: root/Completion/Unix/Command/_user_admin
diff options
context:
space:
mode:
authorJoe Rayhawk <jrayhawk@fairlystable.org>2025-04-30 02:07:56 -0700
committerJoe Rayhawk <jrayhawk@fairlystable.org>2025-04-30 02:07:56 -0700
commit26e09889646be3ea65b4a3dfeda26213e4bb6a27 (patch)
tree4f3c73a9416bf47ad7e125383d23cf42879e38d7 /Completion/Unix/Command/_user_admin
parent841bce705a58b04220b1f257abcc00ae71cbdbdc (diff)
parent001cba48ce3b964cf01fb3e2af54b20eacbc9bf5 (diff)
downloadzsh-26e09889646be3ea65b4a3dfeda26213e4bb6a27.tar.gz
zsh-26e09889646be3ea65b4a3dfeda26213e4bb6a27.zip
Merge branch 'upstream' into debian
Diffstat (limited to 'Completion/Unix/Command/_user_admin')
-rw-r--r--Completion/Unix/Command/_user_admin17
1 files changed, 15 insertions, 2 deletions
diff --git a/Completion/Unix/Command/_user_admin b/Completion/Unix/Command/_user_admin
index db1c977ad..d5a53af7c 100644
--- a/Completion/Unix/Command/_user_admin
+++ b/Completion/Unix/Command/_user_admin
@@ -12,7 +12,7 @@ case ${service%???}:${(M)service%???}:$OSTYPE in
shells=( ${(M)commands:#*/(|[abckz]|tc|ba)sh} )
fi
args+=(
- '(-D -c --commend)'{-c+,--comment=}'[comment]:comment'
+ '(-D -c --comment)'{-c+,--comment=}'[comment]:comment'
'(-D -d --home -b --base-dir)'{-d+,--home=}"[specify home directory]:home directory:_directories -W /"
'(-D -e --expiredate)'{-e+,--expiredate}'[specify expiration date]:expiration date (YYYY-MM-DD)'
'(-D -f --inactive)'{-f+,--inactive=}'[specify inactive days]:inactive days'
@@ -41,6 +41,8 @@ case ${service%???}:${(M)service%???}:$OSTYPE in
SYS_GID_MIN SYS_UID_MAX SYS_UID_MIN UID_MAX UID_MIN UMASK
)
args+=(
+ '--btrfs-subvolume-home[use BTRFS subvolume for home directory]'
+ '(-F --add-subids-for-system)'{-F,--add-subids-for-system}'[add entries to sub[ud]id even when adding a system user]'
'(-l --no-log-init)'{-l,--no-log-init}"[don't add user to lastlog and faillog databases]"
'(-m --create-home -M --no-create-home)'{-M,--no-create-home}"[don't create user's home directory, regardless of /etc/login.defs]"
'(-N --no-user-group -U --user-group)'{-N,--no-user-group}"[don't create a group with the same name as the user]"
@@ -103,6 +105,7 @@ case ${service%???}:${(M)service%???}:$OSTYPE in
user:mod:linux*)
args+=(
'(-a --append)'{-a,--append}'[add user to supplementary groups without removing from other groups]'
+ '(-r --remove)'{-r,--remove}'[remove user from supplementary groups without removing from other groups]'
\*{-v,--add-subuids}'[add a range of subordinate uids]:uids (first-last)'
\*{-V,--del-subuids}'[remove a range of subordinate uids]:uids (first-last)'
\*{-w,--add-subgids}'[add a range of subordinate gids]:gids (first-last)'
@@ -118,9 +121,16 @@ case ${service%???}:${(M)service%???}:$OSTYPE in
;|
user:*:linux*)
args+=(
+ '(-b --badname)'{-b,--badname}"[don't check for bad names]"
'(-U --unlock --lock -L -p)'{-L,--lock}"[lock user's password]"
'(-U --unlock --lock -L -p)'{-U,--unlock}"[unlock user's password]"
- '(-Z --selinux-user)'{-Z,--selinux-user}"[specify SELinux user for the user's login]:user"
+ '(-Z --selinux-user)'{-Z,--selinux-user}"[specify SELinux user for the user's login]:user:_selinux_users"
+ "--selinux-range[specify SELinux MLS range for the user's login]:range"
+ )
+ ;|
+ group:*:linux*)
+ args+=(
+ '(-U --users)'{-U+,--users=}'[specify users to add as members of the group]:user:_sequence _users'
)
;|
group:*)
@@ -164,6 +174,9 @@ case ${service%???}:${(M)service%???}:$OSTYPE in
':group:_groups'
)
;|
+ group:mod:linux*)
+ args+=( '(-a --append)'{-a,--append}'[append the users mentioned by -U without removing existing members]' )
+ ;|
^*:linux*)
args=( ${(R)args:#(|\*)(|\(*\))--*} ) # remove long options
;|