Check Display Server

echo $XDG_SESSION_TYPE