sysconfig/config-debian-xfce.sh
2021-06-19 10:44:18 +08:00

13 lines
360 B
Bash
Executable File

#!/bin/bash
read -p "Enable autologin as user? >>> " UserName
if [ $UserName ]
then
sed -i "s/^.*autologin-user=.*$/autologin-user=$UserName/g" /etc/lightdm/lightdm.conf
sed -i "s/^.*autologin-user-timeout=.*$/autologin-user-timeout=0/g" /etc/lightdm/lightdm.conf
echo "Successfully configured autologin as $UserName"
else
echo 'Nothing changed.'
fi