diff --git a/zsh/.zlogin b/zsh/.zlogin index 4cd88e3..568c292 100755 --- a/zsh/.zlogin +++ b/zsh/.zlogin @@ -1,5 +1,5 @@ emulate sh -c 'source /etc/profile' -if [[ ! $DISPLAY && $XDG_VTNR -eq 1 ]]; then - exec startx +if systemctl -q is-active graphical.target && [[ ! $DISPLAY && "$(tty)" = "/dev/tty1" ]]; then + exec startx fi