LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   konsole or gnome-terminal at startup (http://www.linuxquestions.org/questions/linux-newbie-8/konsole-or-gnome-terminal-at-startup-244792/)

vitaliiluchka 10-19-2004 04:24 PM

konsole or gnome-terminal at startup
 
this must be easy for someone here. How do i make konsole or gnome-terminal to open
at start up when user logs in?

Tinkster 10-19-2004 05:29 PM

Depends on which wm you're using and how you start X
and how they log into the machine ... the most generic
way would be to put a .xsession/.xinitrc file in their home
that does have

xterm
exec <their windowmanager>

as the last two lines (and no exec before those ;})


Cheers,
Tink

Peacedog 10-19-2004 05:32 PM

<edit>Tinkster to the rescue. Quicker than I once again. :) </edit>

vitaliiluchka 10-19-2004 07:44 PM

thanks for your reply Tink
I am new to Linux and don't know much about it.
i followed what you said
1) created directory .xsession in my home directory
2)created file .xinitrc in that directory with following text
xterm
konsole
3) i logged out and tried to log in again but It was unseccesful.
some kind of session error pop up and after i click ok i was send back to logging
window(i use graphical login window and x-windows is KDE)
can you tell me exactly what i have to write in .xinitrc file ?

Depends on which wm you're using and how you start X
and how they log into the machine ... the most generic
way would be to put a .xsession/.xinitrc file in their home
that does have

xterm
exec <their windowmanager>

as the last two lines (and no exec before those ;})


Cheers,
Tink

Tinkster 10-19-2004 10:58 PM

Sorry, my bad.

.xsession and .xinitrc are files... .xsession is being used
if you e.g. use xdm for a login. If the users long in on the
shell and then run startx .xinitrc is being used.

My .xsession file looks like this:
Code:

#!/bin/sh
# $XConsortium: xinitrc.cpp,v 1.4 91/08/22 11:41:34 rws Exp $

userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/usr/X11R6/lib/X11/xinit/.Xresources
sysmodmap=/usr/X11R6/lib/X11/xinit/.Xmodmap

# merge in defaults and keymaps

if [ -f $sysresources ]; then
    xrdb -merge $sysresources
fi

if [ -f $sysmodmap ]; then
    xmodmap $sysmodmap
fi


if [ -f $userresources ]; then
    xrdb -merge $userresources                                                 
fi

if [ -f $usermodmap ]; then
    xmodmap $usermodmap                                                         
fi

/usr/local/bin/tpb&
/usr/X11R6/bin/xscreensaver&
exec /usr/local/bin/fluxbox


Cheers, and good luck
Tink


All times are GMT -5. The time now is 10:47 AM.