CLI reference
CLI overview
Full command surface for the treeship CLI.
Installation
cargo install treeshipAll commands
# Identity
treeship init # set up a new Treeship
treeship status # show state, keys, dock status
# Attestation
treeship wrap -- <cmd> # attest any command execution
treeship attest action # record an action
treeship attest approval # record an approval
treeship attest handoff # record a handoff
treeship attest endorsement # record an endorsement
treeship attest receipt # record a receipt
# Verification
treeship verify <id> # verify an artifact or chain, exit 0/1
treeship verify <id> --format json # machine-readable output
treeship verify <id> --no-chain # verify single artifact, skip chain walk
# Bundle
treeship bundle create # create a bundle from artifacts
treeship bundle export <id> # export a chain as a .treeship file
treeship bundle import <file> # import a .treeship file locally
# Docking (treeship.dev Hub)
treeship dock login # authenticate to the Hub
treeship dock push <id> # push an artifact to the Hub
treeship dock pull <id> # pull an artifact from the Hub
treeship dock status # show dock connection
treeship dock undock # disconnect from the Hub
# Keys
treeship keys list # show key fingerprintsGlobal flags
| Flag | Description |
|---|---|
--config <path> | Config file (default: ~/.treeship/config.json) |
--format <text|json> | Output format (default: text) |
--quiet | Suppress all output except errors |
--no-color | Disable color output |
Environment variables
| Variable | Description |
|---|---|
TREESHIP_ACTOR | Default actor URI for all attestations |
TREESHIP_PARENT | Default parent artifact ID for chain linking |
TREESHIP_LAST | Most recent artifact ID, set after every operation |
TREESHIP_DISABLE | Set to 1 to disable all attestation (passthrough) |
TREESHIP_DEBUG | Set to 1 to log all activity to stderr |
NO_COLOR | Disable color output |
TREESHIP_LAST is updated after every operation. Use it to chain commands without manually tracking artifact IDs.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Success / chain verified clean |
| 1 | Error / chain verification failed |
| 3 | Not initialized -- run treeship init first |
| 4 | Usage error |