Skip to main content
  1. Posts/

Auto Arch Setup

·572 words·3 mins
Computers Arch Automation Bash
Author
Keith Henderson
I am a long time tech enthusiast and gamer. I enjoy creative outlets like art, music and programming.

Automating My Post Install Experience
#

It is always nice booting into a fresh system. The only problem is getting everything setup the way you like after the install is done. Since switching to Linux as my daily driver over a year ago, I have learned a lot in regards to setting up and configuring my system. If you are new to linux you may have heard the term ‘dot’ files. If you are not sure what that means, they are referring to your configuartion files. Typically applications will store configs like themes in your .config folder in the home directory, hence the name ‘dot’ files. This is only part of automating your post install setup, but it is a pretty big one.

Dot, dot, dot
#

If you have not already made a github/gitlab repository for all of your dot files, then why are you still reading this? This has been tremendous time saver for me personally. Most dot files can be made public, so you can easily clone or share them - just make sure they don’t include any sort of sensitive information. For example, I have a repo called GruvDots which contains dot files for a Gruvbox themed hyprland setup I use. When I created this repo, I added my git init right inside my .config folder, then I created a .gitignore file that looks like this:

# Ignore everything in repository root 
/*

# Files to not ignore
!/.gitignore
!/some_other_files

# Folder to not ignore
!/btop/
!/dunst/
!/hypr/
!/kitty/
!/mc/
!/lazynvim/
!/nvim/
!/rofi/
!/wallpapers/
!/waybar/

So what is this doing? This .gitignore will ignore everything in my .config folder, but then it will not ignore the folders I specify. This allows me to easily decide which configs get pushed to my repo.

Automating with Bash
#

Bash scripting is amazing. It is so much fun to create useful bash scripts to help automate things and a post install setup is no exception. When dropping into a fresh Arch install on hyprland, it is pretty bare bones. With a quick install of git, I can leverage this script to automate my install.

  1. It sets my user name for greetd
  2. It installs a list of packages I know I will
  3. It installs yay so I can leverage the AUR
  4. It automatically installs a Gruvbox skin for Midnight Commander
  5. It clones all of my GruvDots from github into my .config folder
  6. It configures my greetd to use tuigreet and themes it
  7. It disables sddm and enabled greetd
  8. It tells me that setup is complete and then asks if I would like to reboot

This all runs within a matter of minutes and my system is setup exactly how I like it. Instantly I am able to start working on whatever I need to.

Home Servers
#

The final piece that really pulls it all together is a home server or some sort of storage like NextCloud. If you have something like this set up then you can keep all of your important stuff you want to save and retain stored on your server and your home pc almost acts like a dummy terminal. If it can’t be a repo on github or saved to your home server then it is basically just installed applications like games and other things you interact with, not actual data. It almost turns your computer itself into a dummy terminal, well it feels like it anyway.

Related

Learning NeoVim
·694 words·4 mins
General Programming Learning Vim Education Computers
My Portfolio
·774 words·4 mins
General Portfolio Music Gaming Computers Work Education
Hello World
·20 words·1 min
General Hello