← All reportsPublic report

wagoodman/dive

A tool for exploring each layer in a docker image

54k stars Go View on GitHubprofiled 11d ago
Try GitZoid
0PRs this week
0Contributors
0Deps scanned
0Issues found
01 · Repo overview

How dive is put together

Dive is a Go CLI/TUI tool for exploring Docker/OCI container images layer-by-layer and estimating wasted space. It resolves an image from one of three sources (Docker engine, Docker tar archive, or Podman engine) via a resolver abstraction, builds per-layer file trees, computes diff/efficiency metrics, and either renders an interactive terminal UI (gocui-based) or, when CI=true, evaluates pass/fail rules and exports JSON. Data flows: resolver -> image/layer analysis -> filetree comparer -> adapter layer -> UI views or CI/export evaluators. Events are dispatched through an internal bus (go-partybus) for progress and errors.

Languages

Go

Frameworks

spf13/cobra (CLI)anchore/clio (app framework/config)awesome-gocui/gocui (terminal UI)charmbracelet/lipgloss (styling)wagoodman/go-partybus + go-progress (eventing/progress)

Infrastructure

Docker Engine API (via docker/docker client, unix socket /var/run/docker.sock)Podman engine (linux-only)Docker image used as distribution vehicle (Dockerfile, ghcr.io/docker.io publishes)goreleaser for release packaging (deb/rpm/brew etc.)GitHub Actions validations workflowTaskfile.yaml + Makefile build orchestration

Major components

CLI entry & commands (cmd/dive)

Wires up the clio/cobra application, version metadata, and subcommands (root/run, build, ci, export, load, config).

Image resolvers (dive/image)

Abstracts fetching image metadata and layers from Docker engine, Docker tar archives, or Podman, selected by --source or source:// prefix.

Filetree analysis (dive/filetree)

Builds per-layer file trees, computes diffs between trees, tracks added/modified/removed nodes, and calculates image efficiency/wasted-space scores.

Command adapters (cmd/dive/cli/internal/command/adapter)

Bridges core analysis into analyzer, evaluator, exporter, and resolver implementations consumed by CLI commands.

CI evaluator (cmd/dive/cli/internal/command/ci)

Evaluates .dive-ci rules (lowestEfficiency, highestWastedBytes, highestUserWastedPercent) to produce pass/fail exit codes.

Export command (cmd/dive/cli/internal/command/export)

Serializes analysis results (e.g., JSON) for machine consumption.

Terminal UI v1 (cmd/dive/cli/internal/ui/v1)

Interactive gocui application with layer view, filetree view, filtering, keybindings, layout manager, and viewmodels; plus a no-UI mode for CI.

Internal bus & logging (internal/bus, internal/log)

Publishes typed events (progress, exploration payloads) and structured logging helpers shared across components.

02 · Weekly changes

No digest this week

1 weeksWeek of

03 · Security check

Dependencies and code review

0 dependencies scanned

Dependency advisories

Security Watch

No known advisories across 0 scanned dependencies.

No known advisories in the scanned dependencies.

Code review

No concrete code-level issues confirmed.

Get this report every week for your repos.

GitZoid learns each repo, reports what changed, and flags what needs attention. One flat price for the whole team.

$19 a month, flat · First 10 outputs free · No card required