Expand description
Tuff capability packs from Rust: build a source pack for its harnesses
and bundle formats, describe a pack for a review screen, read a Claude
Code plugin as a pack, check out a pack from git and compare it with its
release tags, preview an update, write packs as a Claude Code
marketplace, and install, update, and remove packs in a project
(install).
The tuff command is built on these functions, so they behave exactly
as tuff pack and tuff update --check do. They return values and
never print: notes and warnings come back on the result for the caller
to show. They write only to the folders they are given and to temporary
folders, from the system’s temporary directory, that they remove. They
read no environment variables of their own, so they need no HOME;
workspace::Environment::from_process reads them, for a caller that
wants what the tuff command does. git runs as a program and reads the
machine’s git configuration and credentials.
The JSON documents are specified at https://tuffcli.dev/spec/packs/.
The Rust API is 0.x: it can change in a minor release, and each change is in the changelog.
Modules§
- adapter
- build
- Building a source pack into an artifact: every harness target rendered the way an install writes it, and every bundle format written by its adapter crate (RFC-104, RFC-110 D9).
- git
- Packs installed from a git repository (RFC-110 D3, D4, and D12).
- import
- Reading a Claude Code plugin as a pack (RFC-110 D11 and D12): the
import behind
tuff pack importand behind installing a plugin from git, with what the plugin has that Tuff does not carry recorded. - inspect
tuff pack inspect --json(RFC-110 D7): one document a host can build a review screen from. It says what each member is, what it writes on each harness, whether anything in it runs on its own, which MCP servers it starts or connects to, and the host tables the pack carries.- install
- Install, update, and remove packs in a
Workspace, in two steps. - marketplace
- A set of packs written as a Claude Code marketplace (RFC-110 D10): one
plugin per pack under
plugins/<name>/, listed in.claude-plugin/marketplace.json. The CLI’stuff pack marketplace build. - preview
- Previewing a pack update (RFC-110 D5) and finding local edits that block one. Nothing here writes to the workspace.
- workspace
- What the caller passes in: the folder to change, where baseline copies go, and the one opt-in reader of the process environment.
Structs§
- Tuff
Error - One failure, with the kind of thing that went wrong, what happened, and optionally what to do about it.
Enums§
- Error
Kind - What kind of failure this is (RFC-105 D6).