修复用户bug

This commit is contained in:
lsy 2024-09-24 18:32:06 +08:00
parent 470500cc0d
commit 1dc291725b

View File

@ -77,7 +77,7 @@ case $pick in
echo "系统内没有该用户"
exit
fi
sed -i "s/^#\?$user_name.*/d" /etc/sudoers &> /dev/null
sed -i "/^#\?$user_name.*/d" /etc/sudoers &> /dev/null
pkill -u $user_name
userdel -r $user_name &> /dev/null
rm -rf "/home/${user_name}"