Installing dwm ubuntu 10.04
One of the reason for posting this is because the documentation about dwm on ubuntu is fairly rubbish. Note that there is documentation out there (for example here), though it only takes you on your first little step and leave you all on your lonesome. (Boo woo! Whatever, get over it.) Here is a picture from one of the installation guides.Now there are a few problems with this picture.
1) No system tray, which some applications require.
2) The dwm version in the top right corner. (We’re going to replace that with a clock).
3) The configuration still uses the default alt key. This poses a problem with many applications such as firefox, irssi, chrome … etc.
4) No gaplessgrid patch (Personal favorite).
5) No auto-start configuration. Hence you have to manually turn on the internet every time you start.
The aim of this post is to answer these problems, as my memory is not the “may west” acting as a set of notes for myself also.
1. install the dependencies
sudo apt-get install trayer build-essential libx11-dev libxinerama-dev sharutils suckless-tools
2. Download the lastest version which at the time of this post is 6.0. Then unpack it and move into that directory.
tar xvzf dwm-6.0.tar.gz cd dwm-6.0/
3. Download the gaplessgrid patch
4. Replace the config.def.h text with this. Changing the alt key to the windows key, and preparing the gapless grid patch.
5. Install the patch with this command
patch -p1 < dwm-5.2-gaplessgrid.diff
6. Install dwm
sudo make clean install
7. Finally configuring the autostart. Replace vim with whatever text editor you use.
8. Paste the following into this file, taking care of the clock, the system tray and the internet.
9. Set up gdm to auto start that file.
sudo vim /usr/share/xsessions/dwm.desktop
10. And put the following into it.
Name=Dwm Comment=Dynamic window manager
11. Log out and log in to dwm.
WIN + p = run
WIN + SHIFT + ENTER = gnome-terminal
WIN + g = grid WIN + m = Maxiumize
WIN + t = Tile WIN + f = No layout
WIN + 1, 2, … , 9 = Which screens.
Note all the alt key-bindings have been changed to the window key. Now you should have a clock in the top right corner, a tray and nm-applet should be working. As you may have noticed. To load applications or commands at start-up, put them in the ~/.xsession file before exec dwm. If you want a background wallpaper.
sudo apt-get install feh
and use the following command in ~/.xsession file before the exec dwm command.
feh –bg-scale ~/Path/to/Wallpaper.jpg
Hope this helps someone, enjoy!
Here is a screenshot with this background