Add auto startx when using xinit regardless of autologin

This commit is contained in:
natemaia 2019-12-21 16:29:17 -08:00
parent 5f8795d6e9
commit ab643323f3

View File

@ -1678,13 +1678,15 @@ xinit_config()
ExecStart=
ExecStart=-/sbin/agetty --autologin $NEWUSER --noclear %I 38400 linux
EOF
else
rm -rf "$AUTOLOGIN_SERV"
fi
# run `startx` after logging in regardless of autologin
cat > "$MNT/home/$NEWUSER/$LOGINRC" <<- EOF
# automatically run startx when logging in on tty1
[ -z "\$DISPLAY" ] && [ \$XDG_VTNR -eq 1 ] && startx
EOF
else
rm -rf "$AUTOLOGIN_SERV"
fi
}
lightdm_config()