From 7f2ee06e259abb751740f285432c8c345953ce98 Mon Sep 17 00:00:00 2001 From: srdusr Date: Sun, 19 Nov 2023 14:40:21 +0200 Subject: Conditionally set display if x11 --- .profile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.profile b/.profile index 52c4c8d..4aea4fd 100644 --- a/.profile +++ b/.profile @@ -2,5 +2,6 @@ [[ -f ~/.config/zsh/.zshenv ]] && source ~/.config/zsh/.zshenv -#export DISPLAY=:0 -export DISPLAY=:$(echo $XDG_VTNR) +if [ "$XDG_SESSION_TYPE" = "x11" ]; then + export DISPLAY=:0 +fi -- cgit v1.2.3