Thanks for your interest in contributing. Diecast is an Apache-2.0 licensed project for shipping reusable Claude Code agents and skills as a small, opinionated framework. This guide covers what you need to know to send a patch.
git clone [email protected]:sridherj/diecast.git
cd diecastInstaller lands in Phase 4. For now, see
docs/install.mdonce it ships.
./setup # placeholder until Phase 4Diecast ships three layers of tests. Run them in this order when working
on ./setup / /cast-init / /cast-upgrade changes:
-
Python unit tests + bash smoke tests (fast, ~10 s).
uv run pytest -q bash tests/setup-correctness-test.sh
-
End-to-end Docker integration test (slow, 90-120 s). See the "Running the e2e test" section below. Skip on local development unless you are touching install / upgrade plumbing; CI runs it on every push to
mainand on PRs labelledrun-e2e. -
Anonymization lint (instant). Always run before opening a PR:
bin/lint-anonymization
tests/e2e-test.sh orchestrates a full install → /cast-init →
/cast-upgrade → migration-runner walk inside a Docker container. It
uses the fake claude binary at tests/fixtures/fake-claude (Decision
#8) so no API key is needed. Expected runtime: 90-120 s.
Run locally:
docker build -t diecast-e2e -f tests/Dockerfile.test-e2e .
docker run --rm -v "$(pwd):/work" diecast-e2eThe repo is mounted at /work at runtime; rebuild the image only when
the Dockerfile.test-e2e itself changes.
To gate the test on a pull request before merge, add the run-e2e
label. Without the label, only tests/setup-correctness-test.sh runs
on PRs (see .github/workflows/setup-correctness.yml).
| Symptom | Likely cause |
|---|---|
claude: command not found |
Image built without tests/fixtures/fake-claude mounted |
bin/run-migrations.py: Permission denied |
File lost its +x bit on checkout (run chmod +x) |
Test exits 1 with assert_grep miss: skill cast-init … |
/cast-init invocation never reached fake-claude |
| Runtime > 180 s | Docker image cache cold; first build is ~120 s on top of run |
bin/lint-anonymization reports findings |
Internal name leaked into a generated skill or config |
If the test fails for a reason not covered here, file an issue with the
full output of docker run --rm -v "$(pwd):/work" diecast-e2e 2>&1.
- Agents and skills published by this repo use the
cast-*prefix. For example:cast-explore,cast-plan-review. Other prefixes are reserved for upstream internal use and must not appear in public contributions; the anonymization linter will reject them. - Branch names:
feat/<slug>,fix/<slug>,chore/<slug>. - Conventional Commits for messages:
feat:,fix:,docs:,chore:,refactor:,test:.
Diecast is harvested from a private monorepo. The anonymization lint exists to keep upstream-private references (personal email addresses, internal teammate names, internal project paths) out of the public repo.
-
The lint script is
bin/lint-anonymization(lands in sub-phase 1.3). -
CI fails any pull request that introduces a forbidden string.
-
There is no pre-commit hook — run the linter manually before pushing:
bin/lint-anonymization
-
If you add a name to your private memory or notes (for example, a teammate appearing in a personal
CLAUDE.mdPeople table), also add it tobin/lint-anonymization's forbidden list during your next quarterly sweep. The linter is the canonical source of truth for what must never ship publicly.
Goal artifacts and exploration documents use authorship suffixes:
*.human.md— written by a human, not edited by an AI.*.ai.md— written by an AI, lightly reviewed if at all.*.collab.md— co-authored: AI draft with substantial human edits, or vice versa.
Default suffixes:
| Document type | Default suffix |
|---|---|
| Requirements | .human.md |
| Plans | .collab.md |
| Research, summaries | .ai.md |
When a .ai.md accumulates significant human edits, rename it to
.collab.md. Code, configuration, and structured data files (YAML,
JSON, TOML, etc.) do not use the convention.
Before opening a pull request:
- Anonymization-lint passes (
bin/lint-anonymizationreturns 0). - Linked issue or design doc, if applicable.
- Tests added or updated.
- Docs touched in the same PR if behavior changed.
- Conventional Commit message in the PR title.
The pull request template (.github/PULL_REQUEST_TEMPLATE.md) restates
the same checklist for convenience.
Participation is governed by the Contributor Covenant. Report concerns via GitHub Discussions.
Do not open public issues for security vulnerabilities. See SECURITY.md for the private disclosure path.