This post is the continuation of the previous post Arch Linux - Base Installation. Here we are installing X and i3 window manager. Then we install most of the necessary programs that I use daily and configure them. Feel free to skip not relevant steps to you.
Apart from the above, we also add some additional steps that conclude previous blog process, like enabling the Network Manager.
My laptop has Intel graphics, so below command installs Inter graphic drivers and X packages
pacman -S xorg-server xorg-xinit xorg-xinput xorg-xrandr xorg-xdpyinfo xf86-video-intel lib32-mesa-libgl
pacman -S xf86-input-libinput networkmanager network-manager-applet
This will be used with Polybar, so we can control audio from the panel.
pacman -S pasystray pavucontrol paprefs
systemctl enable NetworkManager
Here I install most of the packages that I will require in day to day use
pacman -S net-tools bash-completion gstreamer gst-plugins-ugly libmad zsh git nodejs yarn composer cups cups-pdf ghostscript gsfonts gutenprint dosfstools ntfsprogs tlp reflector pulseaudio pulseaudio-alsa alsa-utils vim wget cmake rsync mongodb-tools python-greenlet zathura zathura-pdf-mupdf calcurse chromium gnome-keyring libgnome-keyring zip unzip python-virtualenvwrapper
Some of the steps below will use yay AUR wrapper, which is discouraged to be used as root user, so we can safely log in now as normal user and use
sudo commands if we require root access. So log out and log back in.
I choose to use yay AUR package manager. Execute below to install it and clean up after.
git clone https://aur.archlinux.org/yay.git cd yay makepkg -si cd .. rm -rf yay
In one of the previous steps we installed Mirrorlist. This package generates the most up-to-date packages for Arch Linux, but also has a flag to rank mirrors. I use it to rank the quickest ones for my location. First backup your current mirrors and then replace them with Reflector:
sudo cp /etc/pacman.d/mirrorlist /etc/pacman.d/mirrorlist.BAK sudo reflector –verbose -l 5 –sort rate –save /etc/pacman.d/mirrorlist
Here we enable TLP, Linux power manager and printing services
sudo tlp start sudo systemctl enable org.cups.cupsd.service sudo gpasswd –add haon lp sudo gpasswd –add haon sys
Preload used to speed up program execution
yay preload –noconfirm sudo systemctl enable preload
oh my zsh is popular zsh framework. I use it for command history autocompletion as well as git aliases when in terminal.
curl -L http://install.ohmyz.sh | sh chsh -s /bin/zsh
To install auto-completion plugin we need to log out and log back in. Then execute below:
git clone git://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions
This step is optional. I copy all of my work and personal SSH keys to
~/.ssh folder and change their permissions
chmod -R 700 ~/.ssh chmod 600 ~/.ssh/* chmod 644 ~/.ssh/.pub chmod 400 ~/.ssh/.pem
Here we start to install i3 and all packages that will complement the workflow. See the links for more info:
sudo pacman -S i3 compton rofi feh termite awesome-terminal-fonts lxappearance scrot pcmanfm gvfs dunst nitrogen imagemagick
yay polybar –noconfirm
yay betterlockscreen –noconfirm
Light is app to control backlight
yay light-git –noconfirm
I do not use any login managers, so below steps will configure Arch Linux to auto login my user, start X and start i3 automatically resulting in me seeing my desktop without the need to first login. Proceed with caution. Think what would happen if your laptop is lost or stolen. I still have no answer to it, by my laptop is like a gem so I guard it :D
sudo vim /email@example.comReplace
ExecStartto look like this (replace USERNAME with your user)
ExecStart=-/sbin/agetty -a USERNAME ? %I $TERMNow we setup X to start i3
cp /etc/X11/xinit/xinitrc ~/.xinitrc vim ~/.xinitrcAdd the following towards the end of the file
xscreensaver & exec i3Because we use zsh, create
~/.zprofilewith the following to make this all work
if [[ ! $DISPLAY && $XDG_VTNR -eq 1 ]]; then exec startx fi
That’s it. You can take it from here or you can follow my next post to have solarized-dark i3 system.