You are not logged in.

#1 2005-04-27 17:57:58

tmadhavan
Member
From: Wales :D
Registered: 2004-03-26
Posts: 441

Login Manager and running .xinitrc commands

Evenin' geezers,

Just a quick one - I'm gonna do a bit more digging around, probably find something, but:

If I want to run, say, Enlightenment, I can stick it in .xinitrc. Then, if I want to run adesklets with it, I can stick that in .xinitrc as well. But, if I want to run some other environments as well, and I use a login manager, how can I get adesklets to load? It doesn't run the .xinitrc script anymore.

So,

a) is there a place to put login scripts that start adesklets regardless off what environment I use?
b) if not, is there somewhere to make the login manager call adesklets somehow?

I'm sure it can't be too complicated, but I can't get it quite right.

Cheers,
Thom

Offline

#2 2005-04-27 18:16:48

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: Login Manager and running .xinitrc commands

There's actually no common "startup file":

startx uses ~/.xinitrc
xdm uses ~/.xsession
kdm/gdm use something I do not know

each WM also has it's own startup file (~/.fluxbox/startup, ~/.wmii/rc, etc)

so... the real answer is: no - if you want a common way to do it, setup each WM you use to run it on startup, otherwise use xdm, or startx...

Offline

#3 2005-04-27 19:48:19

shadowhand
Member
From: MN, USA
Registered: 2004-02-19
Posts: 1,142
Website

Re: Login Manager and running .xinitrc commands

Dirty hack...

ln -s .xinitrc .xsession

I've been using this since I first started using Openbox with GDM.


·¬»· i am shadowhand, powered by webfaction

Offline

#4 2005-04-27 20:35:38

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: Login Manager and running .xinitrc commands

shadowhand wrote:

Dirty hack...

ln -s .xinitrc .xsession

I've been using this since I first started using Openbox with GDM.

I used to do the same with xdm... so gdm uses ~/.xsession as well?

that leaves kdm...

Offline

#5 2005-04-28 00:24:02

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: Login Manager and running .xinitrc commands

For kdm, it's /opt/kde/share/config/kdm/Xsession

Offline

#6 2005-04-28 01:21:34

shadowhand
Member
From: MN, USA
Registered: 2004-02-19
Posts: 1,142
Website

Re: Login Manager and running .xinitrc commands

phrakture wrote:

I used to do the same with xdm... so gdm uses ~/.xsession as well?

Yes, GDM uses .xsession.


·¬»· i am shadowhand, powered by webfaction

Offline

#7 2005-04-28 10:41:20

tmadhavan
Member
From: Wales :D
Registered: 2004-03-26
Posts: 441

Re: Login Manager and running .xinitrc commands

Hang on tho - if I'm running one script, how does the login manager differentiate between what to run when I select different environments?

E.g. my .xinitrc contains 'adesklets & exec enlightenment', right? What if I change my session to KDE - will it still run the .xinitrc that's going to load enlightenment?

To be honest, I hardly ever change sessions anymore, but just so I know.

S, as it stands, I'd need to add

adesklets &
exec enlightenment

to /opt/kde/share/config/kdm/Xsession (if I'm using kdm) and that should hopefully work?

I'm still a littel confused, tho I've got the bit about not being able to do it easily big_smile

Offline

#8 2005-04-28 15:07:00

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: Login Manager and running .xinitrc commands

Personally, I would just set it up with the window manager instead of the display manager - it seems more concise... KDE has a "startup" file somewhere... I'm sure enlightenment does too...

Offline

#9 2005-04-28 16:47:36

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: Login Manager and running .xinitrc commands

If you use kdm, you don't need to have
exec enlightenment
in  .xinitrc.  At the login screen, there is a menu that let you choose wich WM you want to start. You can keep adesklets in  .xinitrc.

Offline

#10 2005-04-28 20:28:34

tmadhavan
Member
From: Wales :D
Registered: 2004-03-26
Posts: 441

Re: Login Manager and running .xinitrc commands

Ah right I see.

Yeah I realise there is a menu in KDM, that's my point tongue I was wondering what script it ran, since it doesn't run .xinitrc... or so I thought. I'll try sticking adesklets in there anyway.

I suppose I could always do away with the login manager altogether, but other people somtimes use the machine and it's easier to just have the usernames there to be clicked...

Offline

#11 2005-04-29 01:14:58

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: Login Manager and running .xinitrc commands

From KDE FAQ:

How do I run a program at KDE startup?
  There are many ways to do that. If what you want to do is to run some scripts that would set some environment variables (for example, to start gpg-agent, ssh-agent and others), you can put these scripts into $KDEHOME/env/ and make sure their names end in .sh. $KDEHOME is usually a folder named .kde (note the period at the beginning) in your home folder. If you want scripts to be executed for all KDE users, you can put them under $KDEDIR/env/, where $KDEDIR is the prefix KDE was installed to (you can find this out using the command kde-config --prefix).

If you wish to start a program after KDE has started, you may want to use the Autostart folder. To add entries to the Autostart folder:
1. Open Konqueror.
2. Select Go->Autostart from the menubar.
3. Right-click in the window view area and select Create New->File->Link to Application
4. Click on the Application tab in the window that appears and enter the name of the command to run in the Command text box.

Offline

#12 2005-04-29 07:21:02

tmadhavan
Member
From: Wales :D
Registered: 2004-03-26
Posts: 441

Re: Login Manager and running .xinitrc commands

I'm using Enlightenment tongue

Offline

#13 2005-05-08 16:19:20

pwe
Member
From: Poland
Registered: 2005-02-15
Posts: 41

Re: Login Manager and running .xinitrc commands

hey!
who knows how i can run xfce4 with xdm ?

-Im using ~/.xsession file
-in inittab & rc.conf is everything OK
-on Gentoo xfce4&xdm worrks fine (exec xfce4-session)

and what i need do in Arch ? Fluxbox is working fine (exec fluxbox)! i dont have any idea hmm
normaly im used to use startx

thanks!

Offline

#14 2005-05-12 20:13:11

shadowhand
Member
From: MN, USA
Registered: 2004-02-19
Posts: 1,142
Website

Re: Login Manager and running .xinitrc commands

Yeah, the command is "startxfce4" not "xfce4-session".


·¬»· i am shadowhand, powered by webfaction

Offline

#15 2005-05-14 00:40:14

pwe
Member
From: Poland
Registered: 2005-02-15
Posts: 41

Re: Login Manager and running .xinitrc commands

ok thanks i try it later, now i dont have much time.

startx -> xfce4-session
gentoo .xsession -> xfce4-session

big_smile

Offline

#16 2005-05-14 01:05:23

T-Dawg
Forum Fellow
From: Charlotte, NC
Registered: 2005-01-29
Posts: 2,736

Re: Login Manager and running .xinitrc commands

Where *in the hell* did you find that avatar?

Offline

#17 2005-05-14 03:59:29

rasat
Forum Fellow
From: Finland
Registered: 2002-12-27
Posts: 2,296
Website

Re: Login Manager and running .xinitrc commands

phrakture wrote:

There's actually no common "startup file":

startx uses ~/.xinitrc
xdm uses ~/.xsession
kdm/gdm use something I do not know

each WM also has it's own startup file (~/.fluxbox/startup, ~/.wmii/rc, etc)

As a quick thought to avoid using a WM, how about having a bash script asking to select what startup file to use?


Markku

Offline

#18 2005-05-14 21:48:32

pwe
Member
From: Poland
Registered: 2005-02-15
Posts: 41

Re: Login Manager and running .xinitrc commands

Penguin wrote:

Where *in the hell* did you find that avatar?

"in the hell or deeper"  wink  really - i forgot. do you like it ?

about XDM -> it dosnt work!  :cry:
exec startxfce4
exec xfce4-session

i cant understand this, sorry. somebody can paste me .xsession here ?

thanks

Offline

#19 2005-05-14 22:09:11

T-Dawg
Forum Fellow
From: Charlotte, NC
Registered: 2005-01-29
Posts: 2,736

Re: Login Manager and running .xinitrc commands

pwe wrote:
Penguin wrote:

Where *in the hell* did you find that avatar?

"in the hell or deeper"  wink  really - i forgot. do you like it ?

Yeah, Its pretty unique. Slow blinking eyes on a bloody pulp looking straight at me while I'm trying to read a post...I can't help but to laugh everytime I see it lol

Offline

Board footer

Powered by FluxBB