add profile.sh to start stdm on tty1

This commit is contained in:
Adrian Schneider 2020-05-29 17:49:28 +02:00
parent f16596632b
commit dcb9ab1458
1 changed files with 8 additions and 0 deletions

8
contrib/profile.sh Normal file
View File

@ -0,0 +1,8 @@
# To avoid potential situation where cdm(1) crashes on every TTY, here we
# default to execute cdm(1) on tty1 only, and leave other TTYs untouched.
if [[ "$(tty)" == '/dev/tty1' ]]; then
[[ -n "$STDM_SPAWN" ]] && return
# Avoid executing cdm(1) when X11 has already been started.
STDM_SPAWN=true exec stdm
fi