View Single Post
  #6   (View Single Post)  
Old 3rd June 2008
ocicat ocicat is offline
Administrator
 
Join Date: Apr 2008
Posts: 3,318
Default

Quote:
Originally Posted by aleunix View Post
I don't see file .xinitrc or .xsession on my directory.
~/.xinitrc and/or ~/.xsession are not present on default installations. Either is simply a text file you create yourself.

Studying /usr/X11R6/bin/startx should answer a number of questions about how X starts. startx determines whether ~/.xinitrc exists & if it does execute it. If not, execute /etc/X11/xinit/xinitrc. If you look at the latter, this has a number of initializations followed by starting a number of X client applications followed by the fvwm(1) window manager.

You can simply edit /etc/X11/xinit/xinitrc & be done with it, but this is a crude solution. The point of looking at the code for startx is to point out that the intention is to allow users to have customized X environments while leaving a default configuration available.

So one could copy /etc/X11/xinit/xinitrc into one's home directory as ~/.xinitrc & customize it locally. Some people simply place whatever applications they want to run into ~/.xinitrc without all the cruft specified in /etc/X11/xinit/xinitrc. It's your choice, but heed how applications are started in the background before the window manager. Failure to understand this can result in a mess.
Reply With Quote