Skip to content

CLI Reference

DepthFusion ships two console scripts installed alongside the package.


depthfusion-audit

Tamper-evident log verification. The audit store is hash-chained — each entry stores the SHA-256 of its predecessor, so any deletion or field mutation is detectable.

depthfusion-audit verify

depthfusion-audit verify [--db PATH]

Walks the audit chain in ascending ID order and checks:

  • chain_break — stored prev_hash does not match the computed hash of the predecessor
  • id_gap — row IDs are non-contiguous (a record was deleted)

Exit codes:

Code Meaning
0 Chain intact — no violations found
1 Violations detected — details printed to stderr
# Default DB (auto-detected from config)
depthfusion-audit verify

# Explicit DB path
depthfusion-audit verify --db /var/lib/depthfusion/audit.db

depthfusion-migrate

Database migration utility. Applies pending schema migrations to the DepthFusion SQLite store.

depthfusion-migrate [--db PATH] [--dry-run]
Flag Description
--db PATH Path to the SQLite database (defaults to configured location)
--dry-run Show pending migrations without applying them

Run after upgrading the depthfusion package to apply any new schema changes. Safe to run repeatedly — migrations are idempotent.