Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

What does the default ~/.vnc/xstartup do in tigervnc?

hi all, i got tigervnc installed on my F20, but have a few questions about the default xstartup file

!/bin/sh

unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
OS=`uname -s`
if [ $OS = 'Linux' ]; then
  case "$WINDOWMANAGER" in
    *gnome*)
      if [ -e /etc/SuSE-release ]; then
        PATH=$PATH:/opt/gnome/bin
        export PATH
      fi
      ;;
  esac
fi

if [ -x /etc/X11/xinit/xinitrc ]; then
  exec /etc/X11/xinit/xinitrc
fi
if [ -f /etc/X11/xinit/xinitrc ]; then
  exec sh /etc/X11/xinit/xinitrc
fi
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
twm &   
exec gnome-session &
exec /usr/bin/startkde &

can someone explain to me what it does ? basically i want to switch to lxde desktop, but i don't know what the majority of the code does. can someone explain this a little bit? thanks.

currently i'm using this ( commented out most of the stuff above )

unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
# exec /usr/bin/startkde &
exec /usr/bin/startlxde &

my understanding of the default one is : unset 2 env var if is on linux and it did something when it's suse linux if /etc/X11/xinit/xinitrc exists, then run this file (twice ?) xsetroot -solid grey # and this is to solve some compatibility issues with some desktop managers, i read it somewhere but don't remeber where

and what does the xterm and twm call do ? and why it runs gnome-session?

i thought i only need one line ( the last line)