Skip to content

Choosing an archetype

Every repo includes common/tasks.toml first, then at most one archetype. The archetype is the repo's primary language: it decides what fmt, lint, build and test mean.

Your repo is… Use
A Go CLI or service (dotty, evolve, gh-claude) go
A TypeScript library or a GitHub Action node
A Python package, or a Zensical docs site with no Go python
A SwiftPM package or CLI swift
A Terraform or OpenTofu module or environment terraform
OCI artifacts published with patchy: a mirror store, images or Flux manifests containers
Markdown and YAML with nothing to build or test common only

What each archetype provides

archetype fmt lint build test extras
go go fmt, golangci-lint --fix, prose, license golangci-lint, govulncheck, license, containers, shell, workflows, prose go build with version ldflags gotestsum, -race, coverage tidy, fuzz, snapshot, release
node check:fix / format scripts, prose, license check / typecheck scripts, license, containers, shell, workflows, prose build script test:coverage script —
python license, ruff format, ruff check --fix, prose ruff check, ruff format --check, license, containers, shell, workflows, prose uv build and/or zensical build pytest (+ pytest-cov) —
swift swift format, prose, license swift format lint --strict, license, containers, shell, workflows, prose swift build -c release swift test, coverage (LCOV) resolve, update, snapshot, release
terraform terraform fmt -recursive, prose validate, tflint, containers, shell, workflows, prose — — init, plan, apply, docs
containers prose, license license, containers, shell, workflows, prose patchy build --all --dry-run, docs site — (repo-local harness) publish, update-allowlists, mirror-*
common prose, license license, containers, shell, workflows, prose — — commit, actionlint, zizmor

Every archetype's lint includes everything common's does: license (except terraform), containers, shell, workflows and prose. The common tasks (commit, license, actionlint, zizmor) are available in every repo.

Root mise.toml per archetype

The root mise.toml differs only in what it pins and which archetype it includes:

archetype root [tools] includes second entry / Makefile include
go go, go:…/govulncheck .mise/archetypes/go/…
node node .mise/archetypes/node/…
python nothing (uv provisions Python) .mise/archetypes/python/…
swift swift .mise/archetypes/swift/…
terraform nothing (opentofu for a tofu repo) .mise/archetypes/terraform/…
containers nothing (every pipeline tool is shared) .mise/archetypes/containers/…
common only nothing no second entry; include .mise/common/include.mk

Why archetypes don't stack

mise merges included task files whole-task, and the later include wins. Every archetype defines its own fmt, lint, build, test, ci and pr, so including a second archetype would silently replace the first's rollups, not merge with them.

Cross-language needs are carried inside an archetype instead:

  • A docs site needs no archetype at all. common ships the Zensical tasks (docs-build, serve), and every archetype's ci and pr end with docs-build (python's build builds the site instead), skipping with a message when there's no zensical.toml. A Go repo with a CLI reference wires docs-build into a repo-local docs task.
  • A Go repo with an embedded web UI adds a repo-local ui task and redefines build to run it before go-build. See Extending & overriding.
  • The python archetype is for repos whose primary language is Python, including docs-only Zensical sites.

Every archetype at a glance

All of them share some structure:

  • Leaf passes are hidden tasks named for the language (go-lint, node-build, py-test, swift-build, tf-fmt).
  • Rollups are sequential composites, so mutating passes never race and fmt precedes lint inside pr.
  • pr ends with commit everywhere except terraform, where it ends with docs.
  • Knobs come from [vars] (structural) or the environment (per run). See Knobs.