First phase of /root. Linux as your daily development substrate.

This is where /root begins: not at programming, not at architecture, not at AI infrastructure, but at the machine you’ll write code on for the next five years. Linux is the substrate every later phase assumes. If the shell is unfamiliar, if ps and top are mysteries, if file permissions are a guessing game, everything later is built on shaky ground.

Phase 1 isn’t kernel internals; that’s Arc 3 territory. This is Linux as a developer uses it: shell fluency, the file system as a navigable space, processes as units of work you can inspect and control, permissions as the security model you live inside, and package management as how you install the rest of your toolchain. By phase end you can sit at any Linux box and operate it without notes.


Prerequisites

  • A Linux environment available: Ubuntu/Debian on a laptop, a Linux VM on your machine, or a small mini-PC. Cloud Linux (a single small EC2/GCE instance) works for parts but local is preferable.
  • Comfort opening a terminal. If cd and ls are genuinely new, spend 2-3 days on a beginner Unix primer before starting.
  • You accept: you are not learning a tool called Linux. You are learning what a developer’s daily substrate is, with Linux as the canonical implementation.

Why this phase exists

Most engineers learn Linux by accident: they hit a problem (permission denied, file not found, command not in path), search Stack Overflow, copy-paste a fix, move on. That works for the first three years of a career and stops working forever after. Senior engineers reason about Linux from understanding, not from memorized commands, because they know the system underneath.

This phase installs that understanding at the developer’s altitude: enough to be fluent on the command line, navigate any file system, operate processes, install packages, and reason about permissions, but not enough to write a kernel module (that’s Arc 3). The bar is: a senior engineer at any company would recognize you as “fluent in Linux” within 5 minutes of watching you work.


The pattern-first frame

Every phase follows the same eight steps. See The Master Plan.

PROBLEM       What category of human need exists?
PRINCIPLES    The timeless patterns any solution must implement
TRADE-OFFS    The decisions every implementation makes
TOOLS         Current implementations (time-stamped — they age)
MASTERY       Pick one tool, go to operational depth
COMPARE       Re-implement the same problem in a second tool
OPERATE       Run it for real, take real incidents
CONTRIBUTE    Ship one fix upstream

1. PROBLEM

You’re a developer. You need a machine that runs your code, hosts your tools, and gives you a stable interface to the system. You want a shell to drive the machine, a file system to organize your work, processes you can inspect and control, package management so you don’t compile every dependency from source, and a permission model that prevents you from breaking things accidentally.

That’s the developer’s-OS problem. Linux is the canonical implementation. macOS is another (Darwin kernel + BSD userland). FreeBSD is another. Windows + WSL is a hybrid. Each implements the same primitives differently. The pattern (unix-style shell + file system + process model + permissions + packages) survives the OS choice; tools age.


2. PRINCIPLES

2.1 The shell as a programmable interface

The shell isn’t just a command runner: it’s a small programming language. Pipes compose commands. Variables hold state. Loops iterate. Functions abstract. Once you see it as a language, scripting stops feeling like cargo-culting and starts feeling like coding.

→ Pattern: shell-fluency

Investigate:

2.2 The file system as a namespace

The file system is a single hierarchical tree starting at /. Devices appear as files (/dev/sda1). Process state appears as files (/proc/PID/). Even network sockets are file descriptors. The “everything is a file” principle isn’t a slogan: it’s the mechanism that makes Unix’s tool composition work.

→ Pattern: file-system-as-namespace

Investigate:

2.3 Processes as the unit of work

Every running program is a process. Processes have IDs, parents, file descriptors, memory, CPU time. The OS gives you tools (ps, top, htop, kill, nohup, &, jobs, fg, bg) to inspect and control them.

→ Pattern: processes-and-permissions

Investigate:

2.4 Users, groups, permissions

Unix permissions are simple: every file has an owner, a group, and a permission triplet (rwxrwxrwx). Every process runs as a user. The intersection determines what’s allowed. Modern Linux extends this with capabilities, ACLs, and SELinux/AppArmor, but the base model is the same.

Investigate:

2.5 Package management

Modern distros ship with package managers (apt, dnf, pacman, apk, brew). They handle dependency resolution, versioning, install/uninstall, security updates. They’re how you stop building every dependency from source.

Investigate:

2.6 The development environment as a discipline

A development environment is the configured state of your machine: shell config, editor, version manager (for Python and Go), credentials, dotfiles, history. Senior engineers version-control this: dotfiles repos, declarative configs (Nix, devbox), or just careful documentation.

Investigate:


3. TRADE-OFFS

DecisionOptionsCost
Shellbash; zsh; fishbash: ubiquitous, legacy syntax. zsh: rich, slight extra config. fish: friendly, fewer scripts compatible.
DistributionUbuntu/Debian; Fedora/RHEL; Arch; NixOSUbuntu: friendly defaults. Fedora: fresher packages. Arch: minimal, you build the system. NixOS: declarative, steeper curve.
Package managerSystem (apt/dnf); brew (cross-platform); NixSystem: ubiquitous. brew: works on macOS too. Nix: reproducible, complex.
Dotfiles managementGit repo + symlinks; chezmoi; Nix home-managerGit: simple, manual. chezmoi: templating + secrets. Nix: declarative, learning curve.
Terminal multiplexertmux; screen; (none)tmux: standard. screen: legacy. None: you’ll wish you had one within a month.
Editorvim/neovim; emacs; VS Code + remote SSH; Helixvim/nvim: ubiquitous. emacs: customizable. VS Code: friendly. Helix: modern modal.

4. TOOLS (as of 2026-06)

Distributions

Core CLI

Modern alternatives (worth trying)

Reading


5. MASTERY: A hardened dev environment

5.1 The deliverable

By phase end, you have:

5.2 Operational depth checklist

[ ] Walk through every file in $HOME for one of your processes (yourself); know what each represents
[ ] Read `man 1 bash`: at least skim the SHELL GRAMMAR section
[ ] Write a shell function that takes arguments, has local variables, and returns a value
[ ] Compose a 4-stage pipeline using pipes (e.g., logs → grep → awk → sort | uniq -c | sort -rn | head)
[ ] Use `find ... -exec` to do something useful (rename, hash, archive)
[ ] Set up SSH keys correctly: ed25519 keys, agent forwarding, ~/.ssh/config with host aliases
[ ] Configure a tmux session with multiple windows + panes; survive a disconnect via tmux attach
[ ] Set up your dotfiles repo + bootstrap script; verify by setting up a fresh VM from it
[ ] Use `ps aux | grep` and `pgrep` to find a running process; kill it with the right signal
[ ] Set up a cron job that emails you on completion (or via a webhook)
[ ] Read 3 entries from `/proc/$$/` (your shell's process directory) and explain what they contain
[ ] Inspect a directory's permissions with `stat`; change them with `chmod` and `chown` and reason about the consequences

5.3 chronicle starts here

chronicle/runbooks/linux-dev-environment/ gets its first 3-5 entries this phase:

Each runbook follows meta/runbook-template.md. The discipline of writing runbooks for your own development environment is what trains the muscle for writing them for production systems later.


6. COMPARE: macOS or FreeBSD

Spend one week on a different Unix:

Write a 400-word reflection in chronicle/: what’s the same? what’s different? what’s the underlying principle?


7. OPERATE


8. CONTRIBUTE

Approachable targets:

This phase is the warm-up for upstream contribution. You’ll attempt your first merged PR in a later phase.


What ships from this phase

No OSS project ships this phase. That starts Phase 2.


Learning loop cadence

Week 1     PROBLEM + PRINCIPLES 2.1-2.2 (shell + file system)
           Start dotfiles repo

Week 2     PRINCIPLES 2.3-2.4 (processes + permissions)
           First operational depth checks

Week 3-4   PRINCIPLES 2.5-2.6 (packages + dev environment)
           Bootstrap script working; tmux + version manager configured

Week 5     MASTERY: full operational checklist
           chronicle runbooks

Week 6     COMPARE: macOS or FreeBSD reflection
           OPERATE + CONTRIBUTE attempt
           Exit Test

Validation criteria

[ ] Dotfiles repo public on GitHub
[ ] Bootstrap script works on a fresh VM
[ ] tmux + version manager + ssh config operational
[ ] All 12 operational depth checks passed
[ ] macOS/FreeBSD compare reflection written (400 words)
[ ] 3-5 runbooks in chronicle
[ ] 1+ ADR
[ ] 5-7 weekly log entries
[ ] Pattern entries deepened STUB → OUTLINE:
    - shell-fluency
    - file-system-as-namespace
    - processes-and-permissions
[ ] Exit Test passed

Exit Test

Time: 2.5 hours.

Part 1: Build (60 min)

Given a fresh Linux VM, run your bootstrap script. After 30 minutes, the environment should be fully usable: shell configured, version managers installed, Python and Go available, tmux running, your editor configured.

Part 2: Diagnose (60 min)

A scenario from the Phase 1 catalog (e.g., “this process is using 100% CPU; identify what it is, why, and stop it gracefully”; or “this user can’t cd into a directory they should have access to; diagnose the permission issue end-to-end”).

Part 3: Articulate (30 min)

~600 words: “Walk through what happens when I type ls -la /etc/passwd | wc -l and press Enter. From the shell’s parsing to the resulting bytes on screen. Cover process creation, pipes, file system access, and the rendering layer.”


Anti-patterns

Anti-patternWhy
Copy-pasting commands you don’t understandThe bug always lives in the line you didn’t read
Skipping the dotfiles repo “for now”The whole point is your environment is reproducible. Without dotfiles repo, you’ll redo this work every time you move machines.
Living in nano because vim/emacs feels hostilePick one modal editor early. The friction up-front pays for itself 100× over the program.
Treating sudo as a magic wordsudo is “do this with elevated privileges.” Know what privileges.
Ignoring man pages “because the internet is faster”Man pages are the canonical reference. They’re sometimes denser than tutorials; they’re also correct and offline.

Patterns touched this phase


→ Next: Phase 2: Programming Foundations I, Python