PackageQuest — Terminal
$ welcome --to PackageQuest
Master every Mac package manager.
From Homebrew to Bun, pip to pixi.
$ start --mode interactive

11 package managers. Interactive quizzes. XP & achievements. Zero boring lectures.

Start Learning →
🍺

Homebrew v5.1.0

The Essential — The missing package manager for macOS

0/6

01 Overview

Homebrew is the de-facto standard package manager for macOS (and Linux), often called "the missing package manager for macOS." It fills a critical gap: while macOS comes with many built-in tools, hundreds of popular developer tools, languages, databases, and utilities are absent.

Homebrew provides a single, consistent CLI to install, update, and remove thousands of open-source packages — from git and python to ffmpeg, postgresql, and node. It manages dependencies automatically, keeps packages updated in a single command, and installs to a sandboxed prefix (/opt/homebrew on Apple Silicon, /usr/local on Intel) so it never interferes with macOS system files.

It also handles GUI macOS applications through its "cask" system, making it a one-stop shop for setting up a development machine.

What's New in 5.1.0 (March 2026)

  • Expanded brew bundle — now manages Rust Cargo packages, uv tools, and Flatpak apps
  • Parallel fetch — downloads all Brewfile deps in parallel before installing
  • brew version-install — install older formula versions in one step
  • Progress bar during concurrent downloads
  • 7-day API cache — reduces network usage

02 Installation

Paste this into macOS Terminal:

bash
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

This downloads and runs the official install script, installs Xcode Command Line Tools if needed, and creates the Homebrew prefix.

After installation on Apple Silicon, add Homebrew to your PATH:

bash
echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ~/.zprofile
eval "$(/opt/homebrew/bin/brew shellenv)"

A .pkg installer is also available from Homebrew's GitHub Releases.

03 Essential Commands

brew install

Install a package (formula) or GUI app (cask).

bash
brew install git
brew install --cask firefox
brew install --verbose node

brew uninstall

Remove a package. Use brew autoremove to clean up orphaned dependencies.

bash
brew uninstall git
brew autoremove

brew update & brew upgrade

update fetches new formula definitions. upgrade installs new versions. Run both:

bash
brew update && brew upgrade && brew cleanup

brew search

Find available packages (formulae and casks).

bash
brew search firefox
brew search /^python/

brew info

Show details about a package: version, dependencies, install path.

bash
brew info git
brew info --json git

brew doctor

Diagnose common problems. Run this first when anything breaks.

bash
brew doctor

brew services

Manage background services (databases, web servers).

bash
brew services start postgresql@16
brew services list
brew services stop --all

brew bundle

Manage all packages from a single Brewfile.

bash
brew bundle dump --describe
brew bundle install
brew bundle check

04 Key Concepts

Formulae vs Casks

Formulae = CLI tools (git, python, ffmpeg). Installed to /opt/homebrew/Cellar/.

Casks = GUI apps (firefox, vscode, iterm2). Installed to /Applications/.

Bottles

Pre-compiled binary packages downloaded from GitHub Container Registry. Makes installation seconds instead of minutes. Architecture and macOS-version specific.

The Cellar

Where all installed packages live (/opt/homebrew/Cellar/). Each formula gets a versioned subdirectory. Homebrew creates symlinks into /opt/homebrew/bin/ for PATH access.

Taps

Git repositories of additional formulae/casks. Built-in: homebrew/core and homebrew/cask. Add third-party taps with brew tap user/repo.

05 Pro Tips

💡
Don't use sudo brew — Homebrew is designed to work without root. Using sudo causes permission problems.
💡
Run brew doctor when things break — it diagnoses 80% of common problems before you even start debugging.
💡
Keep a Brewfile — even for personal use, brew bundle dump --describe gives you a one-command Mac restore.
💡
Use brew autoremove — after uninstalling packages, clean up orphaned dependencies that are no longer needed.
💡
Apple Silicon PATH — if "command not found" after installing, ensure eval "$(/opt/homebrew/bin/brew shellenv)" is in your ~/.zprofile.

06 Quiz

MacPorts v2.12.4

The Secure Alternative — Build from source, full control

0/6

01 Overview

MacPorts is an open-source package management system for macOS dating back to 2002 (originally DarwinPorts). It provides ~29,000+ ports that can be compiled and installed on your Mac.

Unlike Homebrew, MacPorts builds from source by default, installs to /opt/local/ with strict root permissions, and is fully self-contained — bringing its own copies of all dependencies. This makes it more secure and isolated, but slower to install packages.

MacPorts vs Homebrew at a Glance

  • Prefix: /opt/local/ (strict root permissions) vs /opt/homebrew/
  • Install speed: Slower (compiles from source) vs Fast (binary bottles)
  • Requires sudo: Yes, always vs No
  • Port count: ~29,000+ vs ~7,000+ formulae
  • macOS support: Back to Mac OS X 10.5 Leopard vs Rolling drops

02 Installation

Step 1: Install Xcode Command Line Tools:

bash
xcode-select --install

Step 2: Download the .pkg installer for your macOS version from macports.org/install.php. Run the installer.

Step 3: Verify installation:

bash
port version
# Version: 2.12.4

Step 4: Run selfupdate:

bash
sudo port selfupdate

03 Essential Commands

sudo port install

Install a port. Use +variant for build options.

bash
sudo port install git
sudo port install python312 +readline
sudo port install vim +python312 +lua

sudo port selfupdate

Update MacPorts and the ports tree. Always run first.

bash
sudo port selfupdate

sudo port upgrade outdated

Upgrade all outdated ports.

bash
port outdated
sudo port upgrade outdated

port search

Find available ports by name or description.

bash
port search postgresql
port search --description database

port installed

Show all installed ports with versions.

bash
port installed
port installed active

Full Maintenance Sequence

The standard update routine:

bash
sudo port selfupdate
sudo port upgrade outdated
sudo port uninstall inactive
sudo port reclaim

04 Key Concepts

Variants

Build-time options you can enable/disable per port. E.g., sudo port install vim +python312 +lua -x11. Check available variants with port variants <name>.

Self-Contained Dependencies

MacPorts brings its own OpenSSL, readline, zlib, etc. — never relying on macOS system libraries. This means macOS updates almost never break your tools.

Sandboxed Builds

Port builds run in a trace sandbox monitoring all file system access during compilation, catching unexpected behavior.

Snapshots

Before macOS upgrades, save your port list with sudo port snapshot --name "before-upgrade" and restore after reinstalling with sudo port restore --snapshot "before-upgrade".

05 Pro Tips

💡
Always selfupdate first — before installing or upgrading, fetch the latest port definitions.
💡
Expect longer installs — MacPorts compiles from source. Complex packages like GCC may take 20-40 minutes.
💡
Don't mix with Homebrew — you can have both, but avoid installing the same package with both managers.
💡
Use port reclaim — clean up source tarballs and build directories to save disk space.
💡
Check port dependents before uninstalling — see if other ports rely on what you're removing.

06 Quiz

❄️

Nix Declarative

The Declarative — Purely functional, reproducible builds

0/6

01 Overview

Nix is a purely functional, declarative package manager and build system. You describe what you want in a configuration file, and Nix figures out the steps. Building the same expression twice produces identical results, regardless of machine or time.

Key properties: atomic upgrades (never a broken hybrid state), multiple versions coexist without conflicts, and instant rollback to any previous state. The nixpkgs repository contains over 80,000 packages — the largest package repository in the world.

Why Nix on macOS?

  • Single source of truth — entire system setup in version-controlled config files
  • Reproducible dev environments with nix develop
  • Survives macOS major upgrades (Determinate Systems installer)
  • Cross-machine parity between Mac and Linux
  • 80,000+ packages available

02 Installation

Recommended: Determinate Systems Installer (survives macOS upgrades, clean uninstaller):

bash
curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install

After installation, restart your terminal and verify:

bash
nix --version

To uninstall cleanly: /nix/nix-installer uninstall

Official installer (alternative): sh <(curl -L https://nixos.org/nix/install)

03 Essential Commands

nix shell

Temporary shell with packages — they vanish when you exit.

bash
nix shell nixpkgs#ripgrep nixpkgs#bat

nix run

Run a package directly without installing it.

bash
nix run nixpkgs#cowsay -- "Hello, Nix!"

nix develop

Enter a dev environment defined in a flake.

bash
nix develop

nix search

Find packages in nixpkgs.

bash
nix search nixpkgs ripgrep

nix-env

Imperative (traditional) package management.

bash
nix-env -iA nixpkgs.ripgrep
nix-env -e ripgrep
nix-env --rollback

nix build

Build a derivation. Output appears as ./result symlink.

bash
nix build nixpkgs#firefox

04 Key Concepts

Nix Store (/nix/store)

Immutable database of all packages. Each package gets a unique hash-based path. Different versions have different hashes — no conflicts, ever.

Generations & Rollback

Every install/upgrade creates a new numbered "generation." Roll back instantly with nix-env --rollback. Your system is always in a consistent state.

Flakes

The modern way to structure Nix projects. A flake.nix declares inputs and outputs. flake.lock pins exact versions for full reproducibility.

nix-darwin

Declaratively manage your entire macOS — packages, Dock settings, Finder preferences, Homebrew casks, services, and more — all in version-controlled code.

05 Pro Tips

💡
Start with nix shell — experiment before committing. nix shell nixpkgs#python3 gives you Python without installing it.
💡
Use flakes from the start — don't learn channels first. Flakes are where the community is heading.
💡
Search at search.nixos.org — confirm packages exist and find attribute names.
💡
Expect a steep learning curve — Nix's language is unique. Budget weeks for comfort. Start with community starter configs.
💡
Use the Determinate Systems installer — it survives macOS major upgrades and has a clean uninstaller.

06 Quiz

npm

npm v11

The Default — Ships with Node.js, universal standard

0/6

01 Overview

npm (Node Package Manager) is the default package manager that ships with Node.js. It's the oldest and most widely used JavaScript package manager with the largest ecosystem. When you install Node.js, you get npm automatically.

npm v11 was released alongside Node.js 24, requiring Node.js ^20.17.0 || >=22.9.0. Key improvements include faster installs via improved caching, stronger security with --ignore-scripts applying to all lifecycle scripts, and npm init now prompts for ESM vs CommonJS.

02 Installation

npm comes bundled with Node.js. Install via Homebrew:

bash
brew install node

# Verify
node --version   # e.g., v22.x.x
npm --version    # e.g., 11.x.x

To upgrade npm independently:

bash
npm install -g npm@latest

03 Essential Commands

npm init

Create a new project (generates package.json).

bash
npm init
npm init -y   # skip prompts

npm install

Install dependencies from package.json or add new ones.

bash
npm install              # all deps
npm install express      # add production dep
npm install jest -D      # add dev dep
npm ci                   # clean CI install

npm run

Execute scripts defined in package.json.

bash
npm run build
npm test
npm start

npm audit

Check for security vulnerabilities.

bash
npm audit
npm audit fix

npx

Run a package without installing globally.

bash
npx create-react-app my-app

npm list / npm outdated

View and manage installed packages.

bash
npm list --depth=0
npm outdated
npm update

04 Key Concepts

package.json

Project manifest declaring name, version, scripts, dependencies, and metadata. The central file of any Node.js project.

package-lock.json

Exact dependency tree lock file. Always commit this — it ensures all team members install identical versions.

node_modules/

Where installed packages live. Never commit this (add to .gitignore). npm uses a flat structure which can lead to phantom dependencies.

Workspaces

Monorepo support since npm v7. Declare workspace folders in package.json to manage multiple packages in one repo.

05 Pro Tips

💡
Always commit package-lock.json — ensures identical installs across machines.
💡
Use npm ci in CI/CD — faster and cleaner than npm install for pipelines.
💡
Run npm audit regularly — catch security vulnerabilities in dependencies.
💡
Use npx for one-off tools — no need to install globally.
💡
Use -D for dev deps — keep production dependencies clean.

06 Quiz

pnpm

pnpm v10

The Efficient — Content-addressable, disk-saving

0/6

01 Overview

pnpm (Performant npm) solves two major problems: wasted disk space and phantom dependencies. It stores every package version once in a global content-addressable store (~/.pnpm-store) and creates hard links into projects. Ten projects using React means React is on disk only once.

pnpm v10 (January 2025) blocks lifecycle scripts by default for security, uses SHA256 hashing, and introduces an experimental Global Virtual Store for even faster installs.

02 Installation

bash
# Via Homebrew (recommended)
brew install pnpm

# Via npm
npm install -g pnpm

# Via Corepack (ships with Node.js 16.9+)
corepack enable
corepack prepare pnpm@latest --activate

# Verify & upgrade
pnpm --version
pnpm self-update

03 Essential Commands

pnpm add / pnpm remove

Add or remove packages.

bash
pnpm add express
pnpm add jest -D
pnpm remove express

pnpm install

Install all deps. Use --frozen-lockfile in CI.

bash
pnpm install
pnpm install --frozen-lockfile

pnpm run / pnpm dlx

Run scripts or execute packages without installing.

bash
pnpm build   # shorthand
pnpm dlx create-react-app my-app

pnpm store

Manage the global content-addressable store.

bash
pnpm store path
pnpm store status
pnpm store prune

pnpm update

Update packages with interactive picker.

bash
pnpm update --interactive
pnpm update --latest

pnpm why

Explain why a package is installed.

bash
pnpm why express

04 Key Concepts

Content-Addressable Store

Every package version stored once globally in ~/.pnpm-store. Projects get hard links, saving 50-70% disk space vs npm.

Phantom Dependency Prevention

pnpm's strict nested node_modules means you can only import packages you explicitly declared. No accidental dependency on transitive packages.

Security by Default (v10)

Lifecycle scripts are blocked by default — eliminating a major supply chain attack vector. Also supports minimumReleaseAge to block brand-new packages.

Speed

2-3x faster than npm. ~31.9 seconds for a cold Next.js install vs ~57 seconds for npm.

05 Pro Tips

💡
Migrate from npm easilypnpm import converts package-lock.json to pnpm-lock.yaml.
💡
Use pnpm why — understand why a package exists in your dependency tree.
💡
Run scripts without runpnpm build works as shorthand for pnpm run build.

06 Quiz

yarn

Yarn Berry v4

The Innovative — Plug'n'Play, zero-installs

0/6

01 Overview

Yarn was created by Facebook (Meta) in 2016. Yarn Berry (v2-v4) is the modern rewrite with a fundamentally different architecture. Its headline innovation is Plug'n'Play (PnP), which eliminates node_modules entirely.

Yarn v4 highlights: requires Node.js 18+, all official plugins built-in, 3.9x faster than v3 on cold installs, and JavaScript-based constraints engine.

02 Installation

Yarn Berry is installed per project using Corepack:

bash
# Enable Corepack (once)
corepack enable

# Create project with Yarn Berry
mkdir my-project && cd my-project
yarn init -2

# Or set version in existing project
yarn set version stable    # Latest v4.x

03 Essential Commands

yarn add / yarn remove

Add or remove packages.

bash
yarn add express
yarn add jest --dev
yarn remove express

yarn install

Install dependencies. Use --immutable for CI.

bash
yarn install
yarn install --immutable

yarn up

Update packages. Use interactive picker for selective updates.

bash
yarn up express
yarn up "*"
yarn upgrade-interactive

yarn dlx

Execute a package without installing (like npx).

bash
yarn dlx create-react-app my-app

Workspaces

First-class monorepo support with constraints.

bash
yarn workspaces foreach run build
yarn workspaces list

Run scripts

Execute package.json scripts.

bash
yarn build
yarn test
yarn node index.js

04 Key Concepts

Plug'n'Play (PnP)

No node_modules. Packages stored as zips in .yarn/cache/. A single .pnp.cjs file maps all imports. Faster installs, no phantom deps.

Zero-Installs

Commit .yarn/cache/ to Git. Teammates clone and run — no yarn install needed. CI goes from 11 minutes to ~1 minute.

PnP Fallback

If PnP is too disruptive, add nodeLinker: node-modules to .yarnrc.yml for traditional behavior.

Constraints

Enforce rules across workspace packages — e.g., consistent dependency versions. Uses JavaScript engine (v4 replaced Prolog).

05 Pro Tips

💡
PnP needs IDE setup — VSCode requires the ZipFS extension + yarn dlx @yarnpkg/sdks vscode.
💡
Don't confuse Yarn Classic with Berry — v1 is maintenance-only. New projects should always use Berry (v4).
💡
Zero-installs trade-offs — speeds up CI dramatically but increases repo size.

06 Quiz

🥟

Bun v1.3

The Speed Demon — All-in-one JS toolkit, written in Zig

0/6

01 Overview

Bun is an all-in-one JavaScript toolkit — simultaneously a runtime, package manager, bundler, and test runner. Written in Zig on JavaScriptCore (Safari's engine), it's dramatically faster than Node.js-based tools.

Bun v1.3 (October 2025) adds: full-stack dev server, built-in MySQL/PostgreSQL/SQLite/Redis clients, 100x reduction in idle CPU, isolated workspace installs, and bun audit. In November 2025, Anthropic acquired Bun.

Speed Benchmarks (M1 Pro, cold cache, Next.js ~1,100 packages)

  • npm: ~57 seconds
  • pnpm: ~31.9 seconds
  • Bun: ~8.6 seconds (7x faster than npm)

02 Installation

bash
# Method 1: curl (recommended)
curl -fsSL https://bun.sh/install | bash

# Method 2: Homebrew
brew tap oven-sh/bun
brew install bun

# Verify & upgrade
bun --version
bun upgrade

03 Essential Commands

bun add / bun remove

Manage dependencies (blazing fast).

bash
bun add express
bun add jest -d
bun remove express

bun run

Run scripts or TypeScript files directly.

bash
bun run build
bun index.ts    # native TS!

bun test

Built-in test runner (Jest-compatible).

bash
bun test
bun test --watch
bun test --coverage

bun build

Built-in bundler.

bash
bun build ./src/index.ts --outdir ./dist

bunx

Execute packages without installing (like npx).

bash
bunx create-react-app my-app

bun pm / bun audit

Package management utilities & security scanning.

bash
bun pm migrate   # from yarn/pnpm
bun audit
bun outdated

04 Key Concepts

Native TypeScript

Run .ts files directly — no compilation, no tsconfig.json needed to start. Bun strips type annotations at runtime.

Binary Lockfile

bun.lock uses a Structure of Arrays (SoA) binary format — parsed dramatically faster than JSON.

Drop-in npm Replacement

Same package.json, same registry, same node_modules. Reports as Node.js v24.3.0 for compatibility.

All-in-One

Runtime + package manager + bundler + test runner. Replaces Node.js + npm + Webpack + Jest in a single binary.

05 Pro Tips

💡
Migrate lockfilesbun pm migrate converts yarn.lock or pnpm-lock.yaml automatically.
💡
TypeScript doesn't type-check — Bun strips annotations but doesn't validate types. Run bunx tsc --noEmit for type checking.
💡
Not 100% Node.js compatible — most packages work, but native addons and niche APIs may have issues.

06 Quiz

pip

pip Standard

The Classic — Python's default package installer

0/6

01 Overview

pip is the default and official Python package installer, included with Python 3.4+. It installs packages from PyPI (Python Package Index), which hosts over 500,000 packages.

While pip is the starting point for Python development, it has limitations: no lock file by default, slow installs, no Python version management, and no clean uninstalls of transitive dependencies. Modern alternatives like uv are rapidly replacing it.

02 Installation

pip comes with Python. Install Python via Homebrew:

bash
brew install python@3.12

# Verify (use pip3 on macOS)
pip3 --version

# Upgrade pip
pip3 install --upgrade pip

03 Essential Commands

pip install

Install packages from PyPI.

bash
pip install requests
pip install requests==2.31.0
pip install -r requirements.txt

Virtual Environments

Isolate project dependencies with venv.

bash
python3 -m venv .venv
source .venv/bin/activate
pip install flask
deactivate

pip freeze

Export installed packages to requirements format.

bash
pip freeze > requirements.txt

pip list / pip show

View installed packages and details.

bash
pip list
pip show requests
pip install --upgrade requests

04 Key Concepts

Virtual Environments

Isolated Python environments per project. Each gets its own packages with no cross-contamination. Created with python3 -m venv .venv.

requirements.txt

A plain text file listing packages and versions. Not a true lock file — use pip-tools for proper locking, or switch to uv.

Editable Installs

pip install -e . installs your package in development mode — changes to source code take effect immediately.

Limitations

No lock file, no Python version management, slow installs, dirty uninstalls. Full workflow needs pip + venv + pip-tools + pyenv + pipx.

05 Pro Tips

💡
Always use virtual environments — never install packages globally with pip.
💡
Use pip3 on macOS — avoids confusion with system Python 2 (if present).
💡
Consider uv for new projects — it's 10-100x faster and replaces the entire pip+venv+pyenv toolchain.

06 Quiz

uv

uv v0.11+

The Future — 10-100x faster than pip, written in Rust

0/6

01 Overview

uv is an extremely fast, all-in-one Python package manager written in Rust by Astral (creators of Ruff). It replaces pip + pip-tools + pipx + poetry + pyenv + twine + virtualenv — all in a single binary.

As of 2026, uv is the fastest-growing Python tool. Key properties: 10-100x faster than pip (up to 115x with warm cache), built-in Python version management, automatic virtual environments, and a universal lock file (uv.lock).

Speed Benchmarks

  • Install JupyterLab: pip 21.4s vs uv 2.6s (~8x faster)
  • Create virtual environment: ~4s vs ~0.5s (8x faster)
  • With warm cache: up to 115x faster

02 Installation

bash
# Standalone installer (recommended)
curl -LsSf https://astral.sh/uv/install.sh | sh

# Or via Homebrew
brew install uv

# Verify
uv --version

03 Essential Commands

uv init / uv add

Initialize project and add dependencies.

bash
uv init myproject && cd myproject
uv add flask sqlalchemy
uv add --dev pytest ruff

uv run

Run commands in the project's virtual environment.

bash
uv run python main.py
uv run pytest
uv run flask run

uv python

Manage Python versions (replaces pyenv).

bash
uv python install 3.12
uv python list
uv python pin 3.12

uv pip

Drop-in pip replacement (faster).

bash
uv pip install requests
uv pip install -r requirements.txt
uv pip freeze

uvx / uv tool

Run tools without installing (like pipx/npx).

bash
uvx ruff check .
uv tool install black

uv sync / uv lock

Sync environment and manage lock file.

bash
uv sync
uv sync --no-dev
uv lock

04 Key Concepts

One Tool to Rule Them All

Replaces pip + venv + pip-tools + pyenv + pipx. uv add creates .venv + uv.lock automatically.

Universal Lock File

uv.lock tracks exact versions of all direct and transitive dependencies. True reproducibility without pip-tools.

Why So Fast?

No Python startup overhead, CDCL solver, HTTP range requests for metadata, hard-linked cache, true Rust parallelism, 50x faster version comparison.

Drop-in Compatibility

uv pip install X works exactly like pip install X. Zero migration pain for existing projects.

05 Pro Tips

💡
Use uv run instead of activating venvs — it auto-activates the correct environment.
💡
Use uvx for one-off tools — like npx but for Python. uvx ruff check .
💡
Replaces pyenvuv python install 3.12 manages Python versions natively.

06 Quiz

🐍

conda Miniconda

The Data Scientist — Cross-language, binary package management

0/6

01 Overview

conda is a cross-language, cross-platform package manager and environment manager. Unlike pip, conda manages Python packages, binary packages (C/C++ libraries, CUDA, R), and system-level dependencies (compilers, BLAS, MKL).

Conda packages include pre-compiled binaries for each platform — no compilation needed, no Xcode required. It's the tool of choice for data science, machine learning, and scientific computing.

02 Installation

Install Miniconda (minimal, ~100 MB) rather than full Anaconda (~3 GB):

bash
# Apple Silicon (M1/M2/M3/M4)
curl -O https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-arm64.sh
bash Miniconda3-latest-MacOSX-arm64.sh

# Restart terminal, then verify:
conda --version

03 Essential Commands

Environment Management

Create, activate, and manage isolated environments.

bash
conda create --name myenv python=3.11
conda activate myenv
conda deactivate
conda env list
conda remove --name myenv --all

Package Management

Install and update packages.

bash
conda install numpy pandas matplotlib
conda install -c conda-forge tensorflow
conda update --all
conda list

Channels

Configure package sources.

bash
conda config --add channels conda-forge
conda config --set channel_priority strict

Export & Reproduce

Share environments via YAML files.

bash
conda env export > environment.yml
conda create --name myenv --file environment.yml

04 Key Concepts

Binary Packages

Conda's killer feature. conda install pytorch gives you a pre-compiled binary matched to your OS, CPU, and CUDA version. No compilation needed.

Channels

Package repositories. defaults (Anaconda's official), conda-forge (community, 30,000+ packages), bioconda (bioinformatics).

Mixing conda + pip

For PyPI-only packages, use pip inside a conda env. Always install all conda packages first, then pip. Mixing wrong can destabilize environments.

Cross-Language

Not just Python — manages R, C/C++, Rust, and other language packages in a unified system.

05 Pro Tips

💡
Use Miniconda, not Anaconda — install only what you need, not 3 GB of packages.
💡
Set conda-forge as default — more packages, more up-to-date than the defaults channel.
💡
Consider pixi for new projects — it's conda-forge compatible but 10x faster with native lock files.

06 Quiz

pixi

pixi Latest

The Modern — "conda, done right" — Rust-powered

0/6

01 Overview

pixi is a next-generation package manager built on conda-forge by prefix.dev, written in Rust. It uses the same conda package repository but with a modern workflow inspired by Cargo, npm, and Poetry.

pixi is 10x faster than conda, has native lock files (pixi.lock), project-local environments, built-in PyPI integration, and a task runner — no more Makefile or conda activate.

02 Installation

bash
# macOS / Linux
curl -fsSL https://pixi.sh/install.sh | bash

# Restart terminal, then verify:
pixi --version

No Python required. pixi is a single static binary.

03 Essential Commands

pixi init / pixi add

Initialize and add packages.

bash
pixi init myproject && cd myproject
pixi add python numpy pandas
pixi add --pypi requests flask
pixi add --dev pytest

pixi run / pixi shell

Run commands or enter interactive shell.

bash
pixi run python main.py
pixi run pytest
pixi shell

pixi global

Install tools globally (replaces Homebrew for CLI tools).

bash
pixi global install ripgrep bat gh
pixi global list

Tasks

Built-in task runner defined in pixi.toml.

pixi.toml
[tasks]
train = "python train.py"
test  = "python test.py"
start = { cmd = "python start.py", depends_on = ["train"] }

pixi list / pixi tree

View installed packages and dependency tree.

bash
pixi list
pixi tree
pixi search numpy

Migrate from conda

Import existing conda environments.

bash
conda env export > environment.yml
pixi init --import environment.yml

04 Key Concepts

Project-Local Environments

Environments live in .pixi/ inside your project — not in a central ~/conda/envs/. No activation needed.

Native Lock File

pixi.lock provides full reproducibility without a separate tool like conda-lock.

PyPI + conda-forge

Native support for both: conda-forge packages via pixi add and PyPI packages via pixi add --pypi. Uses uv internally for PyPI resolution.

Task Runner

Define tasks in pixi.toml with dependencies. pixi run start runs prerequisites automatically.

05 Pro Tips

💡
pixi uses uv internally for PyPI resolution — the two tools are complementary.
💡
Use for data science / GPU work — pixi shines where conda-forge packages are needed (CUDA, PyTorch, etc.).
💡
Replace Homebrew CLI toolspixi global install ripgrep bat gives isolated installs.

06 Quiz

JavaScript Package Manager Comparison

Featurenpm v11pnpm v10Yarn v4Bun v1.3
Cold Install Speed~57s (baseline)~31s (2-3x)Varies~8.6s (7x)
Disk UsageHigh (copies)Low (50-70% less)Low with PnPSimilar to npm
Phantom DepsPossiblePreventedPrevented (PnP)Prevented
Lockfilepackage-lock.jsonpnpm-lock.yamlyarn.lockbun.lock
Native TypeScriptNoNoNoYes
Monorepo SupportBasicExcellentExcellentGood
Learning CurveMinimalLowModerateLow
npx Equivalentnpxpnpm dlxyarn dlxbunx
CI Installnpm ci--frozen-lockfile--immutable--frozen-lockfile

Command Equivalents

ActionnpmpnpmYarnBun
Install allnpm installpnpm installyarn installbun install
Add depnpm install pkgpnpm add pkgyarn add pkgbun add pkg
Add dev depnpm install pkg -Dpnpm add pkg -Dyarn add pkg -Dbun add pkg -d
Removenpm uninstall pkgpnpm remove pkgyarn remove pkgbun remove pkg
Run scriptnpm run buildpnpm buildyarn buildbun run build
Execute pkgnpx pkgpnpm dlx pkgyarn dlx pkgbunx pkg
Auditnpm auditpnpm audityarn npm auditbun audit

Python Package Manager Comparison

Featurepipuvcondapixi
Written InPythonRustPythonRust
SpeedSlow10-100x fasterSlow10x faster
Lock FileNo (needs pip-tools)uv.lockNo (needs conda-lock)pixi.lock
Python MgmtNo (needs pyenv)Built-inYesYes
Non-Python BinariesNoNoYesYes
Task RunnerNoNoNoYes
conda-forge PkgsNoNoYesYes
Best ForLegacyModern PythonData science/GPUDS + reproducibility