Before you begin, it is important to update your system before you install bspwm. To do this, run the following command in your terminal:
sudo pacman -Syu
In order to install bspwm, you will need to install a few dependencies. Run the following command in your terminal to install them:
sudo pacman -S xorg xorg-xinit xorg-xbacklight
Now that you have all the necessary dependencies, you can now install bspwm. Also Bspwm does not come with a built-in status bar. Therefore, you will need to install a status bar that is compatible with Bspwm. A popular choice is Polybar. To do this, run the following command in your terminal:
sudo pacman -S bspwm
sudo pacman -S polybar
Once the installation is complete, you will need to create a configuration file for Polybar. To do this, run the following command:
polybar example
This will create a configuration file named example.config
in your current directory. You can modify this file to customize your Polybar installation.
Now that bspwm is installed, you will need to configure it. To do this, you need to create a configuration file for bspwm. Create a file called .bspwmrc
in your home directory with the following content:
# bspwmrc
# set the border size
bspc config border_width 2
# set the window gap size
bspc config window_gap 12
# set the window gap size
bspc config split_ratio 0.52
# set the window gap size
bspc config borderless_monocle true
# set the window gap size
bspc config gapless_monocle true
Now that you have everything configured, you can now start bspwm. To do this, you will need to create an xinitrc file. Create a file called .xinitrc
in your home directory with the following content:
# xinitrc
# start bspwm
exec bspwm
exec polybar
Now that you have everything set up, you can now log out of your current session and log in using bspwm.
Congratulations, you have successfully installed bspwm on your Arch Linux system!