DWM is a dynamic, keyboard-driven, tiling window manager developed by Suckless. It’s a great, light-weight window manager that perfectly fits the bill for my malware analysis lab machine.

Unfortunately, it isn’t a simple apt-get away in Ubuntu, but it’s still an easy process to get up and running. Here’s how it’s done.

DWM running on Ubuntu 20.10 LTS

Installation

First off, we need to install a few dependencies:

1sudo apt-get install build-essential libx11-dev libxinerama-dev sharutils suckless-tools libxft-dev stterm

Once this is done, we can download the source for DWM, extract it, and fix the permissions:

1cd /usr/local/src
2sudo wget http://dl.suckless.org/dwm/dwm-6.2.tar.gz
3sudo tar xvzf dwm-6.2.tar.gz
4chown -R `id -u`:`id -g` dwm-6.2

Next, we need to build the project and install it:

1cd dwm-6.2/
2sudo make clean install

At this point, DWM is installed on your system, but we have to do a bit of extra work to get an entry for it on the login screen:

1sudo apt-get install dwm
2sudo cp /usr/share/xsessions/dwm.desktop{,.bak}
3sudo apt-get purge dwm
4sudo mv /usr/share/xsessions/dwm.desktop{.bak,}

Finally, logout and you should be able to select DWM from the login prompt!

Basic Usage

This is here more for my benefit since I’m still getting used to navigating DWM, but here are some of the default key bindings for working with DWM:

  • Alt + Shift + Enter: Launch Terminal
  • Alt + Shift + C: Kill current Client
  • Alt + t: Switch to a Tile Layout
  • Alt + m: Switch to a Monocle Layout
  • Alt + f: Switch to a Floating Layout
  • Alt + p: Launch the demnu
  • Alt + [0-9]: Switch to tag [0-9]
  • Alt + Shift + Q: Quit DWM