You are not logged in.
Pages: 1
I would like to know how to make .xinitrc work with lightdm because I can not do it.
Offline
What do you want to do with .xinitrc ?
Offline
~/.config/openbox/autostart is used to start most of the desktop programs in BunsenLabs, this file is parsed whether LightDM is used or not as long as openbox-session is set as x-session-manager in /etc/alternatives
~/.xsessionrc is used to set environmental variables and suchlike, that file is read by LightDM and most other display managers.
It is also possible to drop .desktop files in ~/.config/autostart and LightDM will honour these as per the freedesktop.org specification.
If you want to use ~/.xinitrc with LightDM then symlink that file to ~/.xsession and select "Default XSession" as the desktop in LightDM.
ln -s ~/.xinitrc ~/.xsession
Or, if you are as allergic to symlinks as I am:
echo ". ~/.xinitrc" > ~/.xsession
I've just checked my Debian jessie system and that uses a slightly more robust version:
# ~/.xsession
/bin/bash --login -i ~/.xinitrc
Offline
Cool stuff Hoas, thanks for some insights. Am currently embroiled in similar Nixish activities which parallel this topic myself. So of course ... Google !!!! Who's how to on autologin + startx + systemd goodness do I come across again ? Hoas's o course and it's a cool share and appreciated too.
Sheesh as long as I've been dorking with gnu/Nix such should be childs play by now. Though as usual am also trying to eat the elephant one bite at a time ... as in, IN ONE BITE.
Fourteen different inter-tangled and similar topics bleeding together. Arghhhhhh! Ok shutting it folks.
Last edited by BLizgreat! (2017-05-29 15:37:02)
Offline
Cool stuff Hoas, thanks for some insights. Am currently embroiled in similar Nixish activities which parallel this topic myself. So of course ... Google !!!! Who's how to on autologin + startx + systemd goodness do I come across again ? Hoas's o course and it's a cool share and appreciated too.
Sheesh as long as I've been dorking with gnu/Nix such should be childs play by now. Though as usual am also trying to eat the elephant one bite at a time ... as in, IN ONE BITE.
Fourteen different inter-tangled and similar topics bleeding together. Arghhhhhh! Ok shutting it folks.
Lay off the caffeine and sugar my friend
Real Men Use Linux
Offline
^ Good point.
Though atm, isn't a realistic prospect. If someone ran the "uptime" command on me, output would be 36+hrs. Still have things to do ! If I stop drinking coffee I'm a goner.
Update: Switched over to high gravity lager, that out to do it. Nappy time is fast approaching.
Last edited by BLizgreat! (2017-05-29 18:29:22)
Offline
.xsessionrc will be read by a LightDm-free plain 'startx' session too.
grep -r '.xsessionrc' /etc/X11
Although it's supposed to be for evvars and the like, you can use any shell commands you want, just like .config/openbox/autostart, and .config/openbox/environment for that matter. The difference of course is that the openbox files won't be run by other window managers.
.xinitrc will likely be ignored by lightdm (haven't tested) and with startx its presence in ~/ will cause all the usual Debian startup commands (see /etc/X11/Xsession.d/) to be skipped, so you have to do everything yourself. Some people might prefer that.
...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )
Offline
+1 John-san, if I've read up correctly, seems ~/.xsessionrc is a Debian and based specific approach to this vs .xinitrc, which supposedly requires being used along with a display manager anyway. So between what John just added and Hoas's how to here. Somebody has everything they need to auto-login and startx without the bloat of a display-manager. Yay !
Thanks Hoas and John.
Pointless afterthought babble:
Though believe Hoa's kickbutt tute will execute default xsession as it is. Whereas John's inclusion and use of an ~/.xsessionrc file should provide a person finer grain control over it. ie: Which gui (Desktop/windows manager)is launched kinda deal ?
From a Debian webpg on how the X startup process works ...
The Debian reference manual describes how the defaults work:
If the user has a ~/.xsessionrc file, read it.
If a specific session was selected in gdm3, run it.
Otherwise, if the user has a ~/.xsession or ~/.Xsession file, run it.
Otherwise, if the /usr/bin/x-session-manager command exists, run it.
Otherwise, if the /usr/bin/x-window-manager command exists, run it.
Otherwise, if the /usr/bin/x-terminal-manager command exists, run it.
No mention of .xinitrc there, though assume some display-managers could check for one and execute if found. That's just a guess and assumption.
Last edited by BLizgreat! (2017-05-30 18:01:50)
Offline
.xinitrc is not needed in the standard Debian boot-up. My understanding is that if it does exist, then a lot of - going on most of - those other files are ignored.
It dates from 2012, but back in #! I dived into this stuff because it was bothering me, and wrote it up. Now reposted here: https://forums.bunsenlabs.org/viewtopic.php?id=3774 If you're interested...
...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )
Offline
I think if ~/.xinitrc is used then Debian assumes that the user wants to specify *exactly* what starts in that file and nowhere else.
Thanks for re-posting that guide johnraff, I keep forgetting about the /etc/X11/Xsession.d quirk :8
EDIT:
No mention of .xinitrc there, though assume some display-managers could check for one and execute if found.
No, display managers will ignore ~/.xinitrc
Last edited by Head_on_a_Stick (2017-06-02 07:09:25)
Offline
Thanks Hoas and already thanked John for posting some useful X/ness in another thread.
Offline
Pages: 1