Developer Tooling
Set up your shell and editor, tame packages and builds, and put linters, type checkers and tests behind one command. Then read and design the CI/CD pipeline that runs it all on every push.
- Beginner
- 4 units, 12 lessons, 156 exercises
- Shell, YAML, JSON
- Builds on Linux & the Shell helps
Unit 01 · 3 lessons
Your workbench
Set up the shell and editor so the things you do a hundred times a day take one step
- 01The shell, set up
How a name is found, aliases and functions, startup files, history search
- 02The editor
Regex search and replace with groups, and the tools that understand code
- BOSSAutomate a chore
From commands you retype to a script, then a named task that fails loudly
Read the unit guide
When you type a name, bash looks in a fixed order: an alias, a function, a builtin, then each folder on PATH from left to right. The first hit wins, and type name tells you which one you got. Most "it runs the wrong version" puzzles end there.
An alias swaps the first word of a command for some text, so arguments can only go on the end. A function is a small script that lives inside the shell: it takes $1, and it can change the shell itself (its folder, its variables), which a script file never can, because a script runs in a child process.
Shortcuts live in startup files. A login shell reads ~/.bash_profile; every other interactive shell reads ~/.bashrc; scripts read neither. Keep aliases and functions in the rc file and have the profile source it. zsh reads ~/.zshrc for every interactive shell. Ctrl-R searches your history, which beats retyping.
In the editor, the regex switch turns search into a language: \b for a word edge, groups in brackets, \1 (or $1) in the replacement. Text tools match letters. For changes that depend on meaning (rename this variable, find its callers) use the language server: one program per language that every editor can talk to.
Anything you do three times becomes a script, and a script others rely on needs a name: a Makefile target or an entry under scripts in package.json. The contract is the exit status. Stop at the first failure (set -euo pipefail), exit non-zero, and everything that calls you (make, &&, a hook, CI) will do the right thing.
The classic pitfalls: a script that carries on after a failed step and reports success, and a make target that shares its name with a folder, which make considers already built until you mark it .PHONY.
Unit 02 · 3 lessons
Packages and builds
Control which versions of other people's code you run, and know what the build does to yours
- 01Dependencies
Semantic versions, ranges with ^ and ~, the lockfile, and what production needs
- 02Environments
Virtual environments, node_modules, pinning the language, and "works on my machine"
- BOSSThe build
Type-check, transpile, bundle, minify: follow one project through, then fix a slow and a broken build
Read the unit guide
A version number is a promise in three parts, MAJOR.MINOR.PATCH: fixes bump the patch, additions bump the minor, and breaking changes bump the major. Your manifest (package.json, pyproject.toml) asks for ranges of versions. ^1.4.2 accepts any later 1.x, ~1.4.2 any later 1.4.x, and a bare 1.4.2 exactly that. Below 1.0 the caret is stricter: ^0.3.1 stays inside 0.3.
A range resolves to whatever is newest on the day you install, and your dependencies have ranges of their own. The lockfile records the exact version of every package in the tree. Commit it, and install from it with npm ci, which fails if the lockfile and the manifest disagree and never rewrites either.
Dependencies you need at run time and tools you need only to build and test are listed apart (dependencies and devDependencies), so production can install the first group alone.
Environments keep projects from fighting. A Python virtual environment is a folder with its own packages; activating it just puts its bin first on PATH, and its python uses the folder's packages even when called by full path. JavaScript resolves an import by walking up from the importing file through each node_modules, so the location of the file decides, and two versions can coexist. Pin the language version too, in a small file that both your version manager and CI read.
A build has four stages: type-check, transpile, bundle, minify. Transpilers strip types without checking them, so the type check is its own step. Bundlers follow imports and drop exports nobody uses (tree shaking), but keep anything that runs at import time. Minifiers rename what is private and leave exported and property names alone. Source maps lead from the shipped file back to your source.
The classic pitfalls: no lockfile ("nobody changed anything" and it broke anyway), pip and python pointing at different installations, and an import whose letter case matches on a Mac but not on Linux.
Unit 03 · 3 lessons
Quality gates
Configure the tools that check code for you, drive a debugger, and put every check behind one command
- 01Linters and formatters
Formatter, linter, type checker: what each is configured to do, and where each one runs
- 02The debugger
Breakpoints, stepping, the call stack and conditions: stop a running program and look inside
- BOSSOne command
Build the single check that guards a project: order it, wire it into CI, and keep it fast
Read the unit guide
Three tools read your code without running it. A formatter rewrites layout (spacing, quotes, line breaks) and has no opinion about meaning. A linter flags suspicious patterns, each one a named rule you can set to off, warn or error. A type checker proves that values fit where they are used. Their settings live in files in the repository, so every editor and every CI machine applies the same rules, and style is argued once, in a review of the config.
Read linter output as line:column severity message rule. Errors make the tool exit non-zero and warnings do not, which is what decides whether a build goes red. --fix repairs findings that have one safe rewrite; anything that needs a decision, such as an unused variable, stays with you. Let the formatter own layout and switch the linter's style rules off, or the two will fight on every save.
Feedback arrives in layers: the editor as you type, the formatter on save, a hook on commit, CI on push, a reviewer last. Each layer is slower than the one before, so catch things as early as they can be caught. Hooks are local and can be skipped, so CI must run the same checks.
A debugger pauses a running program. A breakpoint stops just before its line runs. From there, Step Over runs the line, Step Into enters the call on it, Step Out finishes the current function, and Continue runs to the next breakpoint. The call stack lists every function in mid-flight, newest on top, each frame with its own variables. A condition on a breakpoint skips the thousands of iterations you do not care about.
Put all checks behind one command, and have CI call that command instead of copying its contents. Order the checks cheapest first when you stop at the first failure. Keep the everyday check fast enough that people run it, and move slow suites to CI.
Pitfalls: a hook so slow that everyone skips it, a CI file that lists the checks itself and drifts from the local command, and stepping line by line through a loop when one well-placed breakpoint would do.
Unit 04 · 3 lessons
CI/CD
Read a pipeline file, follow a change from push to production, and design a pipeline you can trust
- 01Continuous integration
Workflows, jobs, steps, triggers and a matrix: read the file that checks every push
- 02Continuous delivery
One artefact, environments and secrets, rolling, blue-green and canary releases, and rollback
- BOSSDesign the pipeline
Design one project's pipeline end to end: what runs on a pull request, what runs on main, and why
Read the unit guide
Continuous integration means a server runs your checks on every push, so a broken combination of changes is found the same afternoon. The examples here use GitHub Actions; other systems use the same ideas under other names. A workflow is a YAML file in the repository. on names the events that start it. Each job runs on a fresh machine chosen by runs-on, and its steps run top to bottom: uses runs a packaged action, run runs a shell command.
Jobs run in parallel unless one needs another, and a job whose prerequisite failed is skipped. A matrix runs one job per combination of its values. Inside a job, a failed step skips the steps after it, and every run is a new shell, so a cd does not carry over. Because each job starts from nothing, a cache keyed on the lockfile saves the downloads.
Continuous delivery carries on after the checks. Build once, label the artefact with its commit, and promote that same artefact through staging to production. What differs between stages (addresses, credentials) comes from each environment's configuration. Secrets are handed to a job by name at run time, never stored in the repository, and never given to code you have not reviewed.
Deployment strategies trade cost against risk. Rolling replaces servers a few at a time. Blue-green runs two full copies and switches traffic, so rollback is a switch back. A canary sends a small share of users to the new version first. Rollback means redeploying the previous artefact, and it only works if the database still suits the old code: add first, remove in a later release.
A pipeline has two halves: on a pull request, verify, with no secrets and no deploys; on a merge to main, deliver. Required checks belong in the branch settings, where nobody can click past them.
Pitfalls: a deploy job that forgot to wait for the checks, re-running flaky tests until red means nothing, and trusting log masking to keep a secret safe.
Learn Developer Tooling on your phone.
Bitpath is an iOS app in development. Join the waitlist and you get one email when it is ready to try.