Package Management
The problem
Installing software by hand means manually finding, downloading, compiling, and tracking every dependency of every tool you use — package managers automate discovery, installation, dependency resolution, and updates, for the entire system's software at once.
Why now
Filesystem navigation gave the ability to place files anywhere; package management is what decides where installed software's files actually go, and — critically — resolves the dependency graph between packages automatically, the same dependency-resolution problem graph theory already proved requires a valid (acyclic) order.
Mental model
A package manager is a specialized database of software plus a dependency-resolution algorithm: installing one package might require several others first, and the package manager computes that install order the same way a build system computes a topological sort of its dependency graph — because it's the identical problem.
Requires
- The Shell & Filesystem NavigationLinux
Package managers install files onto the filesystem tree and are operated entirely from the shell; you need both before 'installing a package' has a concrete meaning.
Helps
- Graph Theory BasicsMathematical Thinking
Resolving which packages must be installed, and in what order, given a web of interdependencies is exactly the topological-sort problem graph-theory-basics already solved — recognizing the connection deepens rather than replaces the practical skill.
Unlocks
Used in
- apt/dnf/pacman for installing system software on Linux distributions
- npm/pip/cargo for installing language-specific libraries — the identical problem, one layer up
- Docker images, largely built by running a distribution's package manager inside a build step
- Dependency conflicts and version pinning, a recurring practical headache with a graph-theoretic root cause
Projects
- Install, update, and remove a package using your system's package manager, observing what dependencies it pulls in automatically
- Deliberately create a version conflict between two packages and diagnose it using the package manager's dependency information
Examples
- apt install nginx automatically installs whatever libraries nginx depends on, without you specifying them
- A 'dependency conflict' error is the package manager reporting that no valid installation order satisfies every package's version constraints
Resources
Mastery checklist
- I can install, update, and remove software using my system's package manager
- I can explain what a dependency conflict is and why it can occur
- I can connect package dependency resolution to the topological sort concept from graph theory
- I can inspect which package a given installed file or binary came from