A Quick Window Manager Install Guide for Arch Linux
The steps for setting up most window managers are the same. Choosing what window manager to use can be difficult, as there are so many options; however, I find that I always make my way back to i3-gaps (a verion of the i3 window manager that supports gaps) and cannot recommend it enough to those interested in using a window manager. The amount of configuration and the simplicity of it is quite nice. So, let’s use i3 as example in this tutorial.
Step 1: Install the Window Manager, Xorg, and Xinit
If you have installed Arch Linux, then this step may seem trivial; however, with window managers (and more often desktop environments) you will likely run into a few otions and i3 is no exception. Simply type the following command to install i3:
$ sudo pacman -S i3 xorg-server xorg-xinit
You will be given some choices of packages to install. Personally, I prefer i3-gaps, so I type
1 3 4 5 and hit
This is the same for most window managers that use X server. Others, like sway, may use Wayland. In that case, you would just need to install Wayland.
Step 2: Copy and Edit .xinitrc
Now that you have i3, xorg, and xinit installed, you are gonna have to set up xinit. To do this simply copy the xinitrc file from
/etc into your user’s home directory:
$ cp /etc/X11/xinit/xinitrc /home/<USER>/.xinitrc
Since this is a configuration file, you probably don’t want it being displayed every time you check your home directory, so you can include a dot at the front of the file name.
Now, you just have to configure Xinit so that when X starts it executes i3. You may wish to sign in as your user for this as there may be some issues This can be done by appending
exec i3 to the bottom of your user’s
.xinitrc file. So, open the file with your favorite text editor:
$ nvim /home/<USER>/.xinitrc
And append the following line:
Step 3: Start X Server
Whenever you sign in as this user, you can now type the command
startx to start the X server. When X server starts, it will automatically execute i3 and you should see the window manager. From here you can hit
Mod+Enter to open up a terminal, then use the
i3-config-wizard command to generate a basic i3 configuration. Personally, I store mine in
.config/i3/config, but you may want this file to be located at
.i3 in your home directory (for easy access).
That is all there is. Really, setting up a window manager is that easy, now all thats left is configuring it to your heart’s desire. As mentioned before, i3 and other window managers offer a lot of customizability, and as a result of this they may seem a bit lacking at first.
So, here is a list of some programs I would recommend using to help spruce up whatever window manager you decide to use:
- polybar - A highly configurable status bar
- urxvt - An incredibly fast and customizable terminal emulator
- neovim - An absolutely fantastic text editor that has a plugin for just about everything you can imagine
- ranger - A terminal based filemanager, perfect for those who don’t want to install all of KDE or Gtk just to move some files around
- zathura - A vim-like document viewer that supports many types of files including EPUBs, PDFs, and even Comic Books
- pywal - A program that can generate and apply color schemes all over your system
I hope this post was helpful and wish you the best with using i3 or whatever window manager you prefer.