Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/lucasgelfond/zerobrew/llms.txt

Use this file to discover all available pages before exploring further.

Displays all packages currently installed by zerobrew, showing their names and versions.

Usage

zb list

Arguments

This command takes no arguments.

Options

--root
path
Environment: ZEROBREW_ROOTOverride the root directory for zerobrew’s content-addressable store.
--prefix
path
Environment: ZEROBREW_PREFIXOverride the prefix directory where packages are linked.
--concurrency
number
Default: 20Number of concurrent operations to perform.
--auto-init
boolean
Alias: --yesEnvironment: ZEROBREW_AUTO_INITAutomatically initialize zerobrew if not already set up.

Output Format

Each installed package is displayed on a single line:
<name> <version>
  • name - The formula name (bold)
  • version - The installed version (dimmed)

Examples

List installed packages

zb list
jq 1.7.1
wget 1.21.4
git 2.44.0
openssl@3 3.2.1
pcre2 10.43
gettext 0.22.5

No packages installed

If you haven’t installed any packages yet:
zb list
No formulas installed.

After installing packages

zb install jq wget
zb list
jq 1.7.1
wget 1.21.4
openssl@3 3.2.1
Note that dependencies (like openssl@3) are also shown.

Use Cases

Check what’s installed

Quickly see all packages managed by zerobrew:
zb list

Export to Brewfile

Use list output to manually create a Brewfile, or use zb bundle dump to do it automatically:
zb bundle dump

Count installed packages

zb list | wc -l
12

Find specific package

zb list | grep node
node 21.6.2

Script usage

Check if a package is installed in a script:
if zb list | grep -q "^jq "; then
  echo "jq is installed"
else
  echo "jq is not installed"
  zb install jq
fi

Implementation Details

The list command reads from zerobrew’s local installation database, which tracks:
  • Formula name
  • Installed version
  • Store key (content-addressable hash)
  • Installation timestamp
  • Link status
For more detailed information about a specific package, use zb info.

Comparison with Homebrew

FeaturezerobrewHomebrew
List installedzb listbrew list
Output formatname + versionname only (or verbose)
Show dependenciesYesWith --formula
Machine-readableOutput is parseableUse brew list --json

Performance

The list command is instant, as it reads from a local SQLite database rather than scanning the filesystem:
time zb list > /dev/null
0.01s user 0.00s system 95% cpu 0.012 total