From c4219833b4752bb0ad027742e8beb5a6518960e8 Mon Sep 17 00:00:00 2001 From: krolyxon Date: Sun, 31 Jul 2022 13:24:13 +0530 Subject: .xinitrc change --- .config/shell/profile | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to '.config/shell/profile') diff --git a/.config/shell/profile b/.config/shell/profile index f0172c9..0933809 100644 --- a/.config/shell/profile +++ b/.config/shell/profile @@ -198,8 +198,5 @@ ex=:\ *.nix=:\ " -# Starting X -if [ -z "${DISPLAY}" ] && [ "${XDG_VTNR}" -eq 1 ]; then - exec startx -fi - +# Start graphical server on user's current tty if not already running. +[ "$(tty)" = "/dev/tty1" ] && ! pidof -s Xorg >/dev/null 2>&1 && exec startx "$XINITRC" -- cgit v1.2.3