Darryl Dias

24 Jun 2015 in

BSPWM (Binary Space Partitioning Window Manager) is a tiling window manager based on binary space partitioning, which represents windows as the leaves of a full binary tree. It is written completely in C. BSPWM is easy to customize and set up. Let's install BSPWM by following the instructions below.

This has been tried and tested on Debian Jessie and Testing.

Installing the required dependencies.

<pre class="wp-block-code">```
sudo apt-get install git gcc make xcb libxcb-util0-dev libxcb-ewmh-dev libxcb-randr0-dev libxcb-icccm4-dev libxcb-keysyms1-dev libxcb-xinerama0-dev libxcb-ewmh2

Cloning BSPWM git repository.
```
git clone https://github.com/baskerville/bspwm.git  
```
```

Cloning SXHKD git repository.

```
```
git clone https://github.com/baskerville/sxhkd.git  
```
```

Build and install BSPWM and SXHKD.

Enter the `bspwm` directory.

```
```
cd bspwm
```
```

Building and installing BSPWM using Make.

```
```
make
```
```

```
```
sudo make install
```
```

Exiting the bspwm directory after make has completed building and installing BSPWM.

```
```
cd ..  
```
```

Entering into `sxhkd`.

```
```
cd sxhkd/ 
```
```

Building and installing `SXHKD`.

```
```
make  
```
```

```
```
sudo make install  
```
```

Creating `~/.config/bspwm` and `~/.config/sxhkd` directory to store configuration and dotfiles used by it.

```
```
mkdir ~/.config/bspwm  
```
```

```
```
mkdir ~/.config/sxhkd  
```
```

Copying the configuration files used by BPSWM. and SXHKD

```
```
cp -T bspwm/examples/bspwmrc `~/.config/bspwm/bspwmrc`  
```
```

```
```
cd .. 
```
```

```
```
cd sxhkd/  
```
```

```
```
cp -T bspwm/examples/sxhkdrc ~/.config/sxhkd/sxhkdrc  
```
```

Turning the file into an executable.

```
```
sudo chmod +x ~/.config/bspwm/bspwmrc  
```
```

Coping the `bspwm-session` file to `/usr/bin/`.

```
```
sudo cp -T bspwm/contrib/freedesktop/bspwm-session /usr/bin/bspwm-session  
```
```

If you use `xinitrc` file to manage your DE, you can update your `.xinitrc` to log you into it.

```
```
exec bspwm-session  
```
```

You can edit the `~/.config/bspwm/bspwmrc` to add scripts, services, and applications to the startup.

To change your keyboard shortcuts simple, edit the `~/.config/sxhkd/sxhkdrc`.

You might want to add the following to the `bspwmrc`, this will set your mouse pointer to a left-pointing arrow instead of the default X of Xorg.

```
```
xsetroot -cursor_name left_ptr &  
```
```

Now we are done setting up BSPWM on Debian. If you have any questions feel free to leave a comment below.