Jump to content

DWM and ST install Guide (Arch Linux)

So you are wondering how to install DWM on Arch Linux? Well look no further! In this post I am going to show you how to install DWM and get it working!


Preamble

 

Spoiler

1.PNG.ada1ad45a27de0f70495e97efee66163.PNG

I am using Arch Linux with Linux kernel 5.15.2-arch1-1

 

STEP 1

 

Lets create a new user. In this case our user will be called DWM. This is done by by useradd -m dwm. You must remember to add -m to the command otherwise it will not create a directory for your user.

useradd -m dwm

passwd dwm
Spoiler

2.PNG.73033d5eef8e61564d9c8154e4150cbe.PNG

 

STEP 2

 

Now you want to give your new user sudo permissions. This can be done by going into the sudoers file in /etc/sudoers with your favorite text editor.

Once you are in the sudoers file you want to scroll down to User privilege specification and add your user. As you can see here we have 3.

root, nick and dwm. DWM is the one we are working with now.

 

Once that is done we move onto step 3.

Spoiler

sudoers.PNG.4a8189b675fe6aa45eac90f66c73e966.PNG

 

STEP 3

 

Now that the dwm user has been created we can now log into it and download the packages we need.

Lets also download Firefox now as well.

 

sudo pacman -S xorg-server xorg-xinit xorg-xrandr xorg-xsetroot firefox 
Spoiler

3.PNG.7f9d745eea7f27270fff466f3d280782.PNG

 

STEP 4

 

Once everything has been downloaded and installed we need to copy the xinitrc file to our home directory with the following command.

 

cp /etc/X11/xinit/xinitrc .xinitrc
Spoiler

4.PNG.8e4da6ebfd60485fd175cb56e2ca4ca0.PNG

 

STEP 5

 

If everything has gone well so far your home directory should look something like this...

 

Spoiler

5.PNG.361e79badf541480f8a90956b2e1a589.PNG

 

STEP 6

 

Once that has been done and we have confirmed xinitrc is in the correct place. We need to go into the file using a text editor and make a change.

So open the file and go down to the very bottom and remove the last 4 lines.

Once that is done replace them with exec dwm 

 

It should go from this

Spoiler

6.png.f871828dc9fc27aaa358ff32df8d0f2e.png

 

To this

Spoiler

29026043_xinitrcchange.PNG.ff336361aa7ce777b45d87a2be819257.PNG

Once that is done we move onto step 7

 

STEP 7

 

Now we move onto download the software we need. We will be downloading 2 git packages from suckless.org

git clone https://git.suckless.org/dwm
git clone https://git.suckless.org/st

Once they have both been downloaded we need to CD into them and compile the software with

sudo make clean install

The output from the compiling should look something like this

 

Spoiler

435662003_dwmcomplile.PNG.6c6ea069b102db5aee0d4d5ff7a231f0.PNG

Don't mind that the user says root@tut. I forgot to get a screenshot when compiling earlier on.

Once that is done we can now move onto the final step.

 

FINAL STEP

 

All that is left now is to type 

startx

And it should give a desktop that looks something like this!

Spoiler

9.PNG.f1bafaf87537b7a7fec716633cb71d02.PNG

 

You have now installed DWM and Simple terminal on Arch Linux!

 

This should work on any Linux Operating system but of course keep in mind your install manager EG changing sudo pacman -S to sudo apt install.

 

If you want to follow it along in a video format I made a video here as a guide.

Spoiler

 


I hope you find this guide useful. Have a good rest of your day!

Nick Matthews
LinuxPanic

Edited by Nick4853
Link to comment
Share on other sites

Link to post
Share on other sites

1 hour ago, Nick4853 said:

Now you want to give your new user sudo permissions. This can be done by going into the sudoers file in /etc/sudoers with your favorite text editor.

Why not just use the wheel group like your supposed to do?

Link to comment
Share on other sites

Link to post
Share on other sites

On 11/17/2021 at 9:11 PM, 10leej said:

Why not just use the wheel group like your supposed to do?

I find this is easier to do and explain to new users. I will be expanding on this in the future.

Link to comment
Share on other sites

Link to post
Share on other sites

3 hours ago, Nick4853 said:

I find this is easier to do and explain to new users. I will be expanding on this in the future.

How so?

useradd -m new_user -G wheel
echo '%wheel ALL=(ALL) ALL' > /etc/sudoers.d/wheel

 

I mean there is really nothing wrong with adding it on a user basis, but unless your restricting a users sudo actions, there is little reason to.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×