Complete Script Breakdown - Simple Developer's Guide
Complete Script Breakdown - Simple Developer's Guide
Before: You type commands manually, everything looks plain, you spend time setting up each project
from scratch.
After: Your terminal predicts what you want, everything has colors and icons, and creating new projects
takes 30 seconds instead of 30 minutes.
Section-by-Section Breakdown
bash
What it does: Makes the script super careful - if anything goes wrong, it stops immediately instead of
breaking your system.
Why it matters: Prevents the "oh crap, I broke my computer" moments. It's like having airbags in your car.
bash
RED='\033[0;31m'
GREEN='\033[0;32m'
# ��� etc
What it does: Makes script messages colorful so you can instantly see:
Why it matters: Instead of staring at walls of boring white text, you immediately know what's happening.
Section 2: System Update
bash
What it does: Updates all your installed software to the latest versions automatically.
Real-world impact:
• After: Always running latest versions with bug fixes and security updates
What paru does: It's like having an assistant who can install software from both the official store AND the
community store, automatically.
Before paru:
bash
After paru:
bash
paru -S some�package
# Takes 30 seconds, handles everything automatically
bash
• github-cli: Control GitHub from terminal (create repos, pull requests, etc.)
• git-delta: Makes git diffs beautiful with syntax highlighting and better formatting
• lazygit: Visual git interface - like having a GUI for git inside terminal
After (git-delta):
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
src/user.js
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
1 │ const name = 'john' │ const name = 'jane'
│ ────────────────── │ ─────────────────
bash
[user@arch ~]$
• tmux: Lets you have multiple terminal sessions, split screens, persist sessions even when you close
the terminal
• starship: The fancy prompt you see above with git status, language versions, etc.
bash
These replace standard Unix tools with modern, faster, prettier versions:
File viewing - cat → bat : Before: Plain text, no syntax highlighting After: Syntax highlighting, line
numbers, git integration
File searching - find → fd : Before: find . -name "*.py" -type f After: fd .py (90% faster,
respects .gitignore automatically)
Text searching - grep → ripgrep : Before: grep -r "function" . After: rg "function" (10x
faster, better output formatting)
Fuzzy finding - fzf : This is a game-changer. Press Ctrl+T and instantly search through all files:
> controllers/user
1/847
❯ src/controllers/userController.js
src/models/userModel.js
tests/user.test.js
Daily time savings: These tools combined save 15-20 minutes per day of navigation and searching.
bash
# Python ecosystem
"python" "python�pip" "python�virtualenv" "python�pipenv"
# JavaScript ecosystem
"nodejs" "npm" "yarn" "pnpm"
# Other languages
"rustup" "go" "jdk�openjdk" "maven" "gradle"
Before: Installing a language takes 30-60 minutes of research and setup After: All major languages ready
to use immediately
bash
What Docker does: Lets you run applications in isolated containers. Think of it like having multiple mini-
computers inside your computer.
Real-world example: Without Docker: "It works on my machine" problems when sharing code With
Docker: Code runs identically on your machine, your colleague's machine, and production servers
Before: Setting up databases, web servers, etc. takes hours After: docker run postgres gives you a
database in 30 seconds
Database Tools
bash
• Multiple database systems: SQL databases (PostgreSQL, MySQL, SQLite) and a fast cache (Redis)
• Visual database tools: DBeaver and MySQL Workbench let you manage databases with a GUI instead
of command line
Before: Database setup is a day-long nightmare After: Databases available instantly, manageable with
pretty interfaces
Network Tools
bash
• wget/curl: Download files and make web requests from command line
Before: Testing APIs requires complex curl commands After: Beautiful, simple tools for web
development
bash
bash
What this does: Sets up Git with modern best practices automatically.
Before: Every git operation shows plain, hard-to-read output After: Beautiful, colorized git operations with
better conflict resolution
Specific improvements:
• Default branch: Uses main instead of outdated master
• Editor: Opens Neovim for commit messages (much better than nano)
Shell Theme
bash
ZSH_THEME="agnoster"
What it does: Changes your prompt from boring $ to a powerline-style prompt with colors and
information.
Plugins List
bash
plugins=(
git # Git shortcuts and status
zsh�autosuggestions # Suggests commands as you type
zsh�syntax�highlighting # Colors commands
docker # Docker shortcuts
kubectl # Kubernetes shortcuts
npm # Node.js shortcuts
python # Python shortcuts
rust # Rust shortcuts
golang # Go shortcuts
archlinux # Arch�specif�c shortcuts
)
• git plugin: Adds shortcuts like gst for git status , gco for git checkout
• language plugins: Add shortcuts and autocompletion for each programming language
File Operations:
bash
System Monitoring:
bash
Development Shortcuts:
bash
Docker Shortcuts:
bash
Package Management:
bash
Time savings: These aliases save 50-100 keystrokes per hour of work.
Custom Functions
mkcd function:
bash
Before: mkdir new-folder then cd new-folder (two commands) After: mkcd new-folder (one
command that creates and enters directory)
extract function:
bash
extract() {
# Handles .tar.gz, .zip, .rar, .7z, etc.
}
Before: Remember different commands for each archive type After: extract filename.anything
works for all archive types
Environment Variables
bash
What this does: Sets up your system so all programs know your preferences automatically.
Before: Opening a file in vim shows plain text, no line numbers, confusing navigation After: Professional
editor with line numbers, proper indentation, syntax highlighting
• Space + q : Quit
Daily impact: Text editing becomes 3-5x faster with proper shortcuts and visual aids.
bash
mkdir �p "$HOME/Development"/{Projects,Learning,Tools,Scripts,Experiments}
mkdir �p "$HOME/Documents"/{Notes,Books,Papers,Tutorials}
mkdir �p "$HOME/.local/bin"
Before: Files scattered everywhere, hard to find projects After: Everything organized logically, muscle
memory develops for file locations
Docker Service:
bash
• Adds you to the docker group so you don't need sudo for docker commands
Before: docker run hello-world → "Permission denied" After: docker run hello-world → Works
perfectly
The script asks if you want PostgreSQL and Redis to start automatically.
If you say yes: Databases available instantly when you need them If you say no: You can start them
manually when needed
newproject Script
This creates a magic command that sets up entire projects instantly:
bash
Before: Setting up a new Python project takes 15-30 minutes of manual work After: 30 seconds, project
is ready for coding
cleanup Script
bash
cleanup
Before: System cleanup is 15+ manual commands you probably forget After: One command cleans
everything, runs in 2 minutes
When to use: Run cleanup once a week to keep your system fast and free up disk space
bash
Why it matters: These tools integrate perfectly with your LXQT desktop environment.
Rust Toolchain:
bash
bash
Python Packages:
bash
pip install ��user virtualenv pipenv black flake8 pytest requests django flask fastapi
# Start working
code .
# Wait for VS Code to load
# Remember what f�les you were editing
# Check git status again
# Start coding���
bash
# Start working
code . # Opens instantly to last session
AFTER:
bash
bash
AFTER:
bash
btop
# Instantly see beautiful graphs
# Processes sorted by CPU/memory usage
# Click or arrow�key navigate
# Instantly understand what's wrong
File Operations (Before vs After)
BEFORE:
bash
AFTER:
bash
bash
git status
git add .
git commit �m "Add user authentication"
git push origin feature/user�login
# Plain text output, hard to see what's happening
AFTER:
bash
Terminal Speed
• Command completion: 70% less typing due to intelligent autocompletion
• Navigation speed: 80% faster due to better tools (fd, rg, fzf)
Development Speed
• Project setup: 95% time reduction (30 seconds vs 30 minutes)
• File navigation: 60% faster due to fuzzy finding and better listing
System Performance
• Resource usage: Better monitoring means you catch performance issues early
Learning Curve
• Week 1: Adjustment period, everything feels different
• Lightning-fast navigation: Watch others struggle with basic commands while you fly through tasks
• Knowledge sharing: Your organized directory structure makes it easy to find and share code
• Efficiency demonstration: Others will want to learn your shortcuts and setup
• Productivity awareness: Shows you think about optimizing your development environment
What to Do First
1. Run the script: ./setup_dev_env.sh
Getting Help
• All tools installed have --help flags
Bottom Line
This script transforms your basic Arch Linux setup into a professional development powerhouse. Instead
of fighting with tools, you'll have tools that work with you. Instead of remembering dozens of commands,
you'll have shortcuts and automation. Instead of spending time on setup and maintenance, you'll spend
time on actual development.
The goal: Make your computer an extension of your thinking, not an obstacle to it.
The result: You become a more productive, less frustrated, and more capable developer.
Time investment: 45 minutes to run the script and learn basics Time savings: 1-2 hours per day forever