[howto] Debian Wheezy : lightdm + i3
asked 2013-09-05 08:29:28 +0000
This post is a wiki. Anyone with karma >100 is welcome to improve it.
Hi,
I don't have a blog, but this information is important to be indexed by web search, prism, nsa and partners.
(note: I use lightdm stable, and i3 backported)
I see some problems with lightdm and i3. This make me try: ligthdm, slim, xinit, thinking about compiling lxdm... (and count several days of thinking). I use xfce4-power-manager, and with some solution, I lost capability to suspend or hibernate with this application... Due to my difficult to document me from this problem, I will help you in two (fundamental) customizations that now I solved:
- Select i3 as default in lightdm
- Add your ~/bin for scripts in dmenu for execution
1 - Select i3 as default in ligthdm
This will NOT SHOW i3 as a WM to make it default:
$ update-alternatives --config x-session-manager
you have to go edit lightdm configuration's file:
$ nano /etc/lightdm/lightdm.conf
and change that line: user-session=i3
This will make i3 as "default" when you login.
2 - Add your ~/bin for scripts in dmenu for execution
First you say: why I cannot execute commands in dmenu?
I made some stuff I readed as rm ~/.dmenu_cache
or dmenu_path | grep <myapp>
and sometimes appear to be listed by dmenu, but never executed. You can try to export $PATH with your bin directory in .bashrc, .profile, .bashrc_profile, ... It will not work.
A good point to solve this, was:
cat /proc/$(pidof i3)/environ | tr '\0' '\n' | grep '^PATH'
Suggested by a partner in official irc #i3 (thanks!). With this, we will see that our binary isn't in the PATH of i3. And to make it work on Debian + lightdm + i3, we have to put in the appropiate way. As said in /etc/lightdm/lightdm.conf , the wrapper is:
session-wrapper=/etc/X11/Xsession
If we go in, that shows:
USERXSESSION=$HOME/.xsession
USERXSESSIONRC=$HOME/.xsessionrc
ALTUSERXSESSION=$HOME/.Xsession
That means, this 3 files are inspected by lightdm in the moment of initializing i3. If you put here scripts, this will take effect to i3. For debian, you should use .xsessionrc (the other are ignored) and put something like this:
export PATH=$HOME/bin:$PATH
And that's it!
I made this post community wiki, and I don't have reputation to edit this. The tags are incorrect, should be: debian, dmenu, path, lightdm. And you will find some mistakes in the text. Sorry
Thanks for your contribution! Upvoted question for karma :) Better stick to the Q&A style of the site next time.
Thanks this helped me too!