if [ -z $DISPLAY ] && [ $(tty) = /dev/tty1 ] then startx -- -nocursor exit sudo reboot fi