Blob Blame History Raw
--- a/scripts/startxfce4.in	
+++ a/scripts/startxfce4.in	
@@ -108,13 +108,15 @@ then
   SERVERRC="-- $SERVERRC"
 fi
 
+tty_num=$(echo $(tty | grep -o '[0-9]'))
+
 if [ -f $BASEDIR/xinitrc ]; then
-  exec $prog $BASEDIR/xinitrc $CLIENTRC $SERVERRC
+  exec $prog $BASEDIR/xinitrc $CLIENTRC $SERVERRC -- vt${tty_num}
 elif [ -f $HOME/.xfce4/xinitrc ]; then
   mkdir -p $BASEDIR
   cp $HOME/.xfce4/xinitrc $BASEDIR/
-  exec $prog $BASEDIR/xinitrc $CLIENTRC $SERVERRC
+  exec $prog $BASEDIR/xinitrc $CLIENTRC $SERVERRC -- vt${tty_num}
 else
-  exec $prog @_sysconfdir_@/xdg/xfce4/xinitrc $CLIENTRC $SERVERRC
+  exec $prog @_sysconfdir_@/xdg/xfce4/xinitrc $CLIENTRC $SERVERRC -- vt${tty_num}
 fi