4.7 KiB
Kanban documentation bootstrap and validation
Use this when a project documentation site has authoritative Scope and Architecture records but no dedicated Kanban area yet.
Bootstrap sequence
- Start from a clean clone of the current documentation integration branch. Do not reuse a worktree with unrelated modifications.
- Read current Scope records plus Architecture, Delivery, Releases, and enough Kanban-channel history to establish approval and execution evidence.
- Add a dedicated Docusaurus docs plugin for
kanban/, with its ownsidebarsKanban.ts. - Place the top-level Kanban navigation item immediately after Architecture and add
/kanbanto documentation search indexing. - Add exactly two sidebar entries in this order: Board, Focus.
- Populate Board from authoritative unfinished Epic and Feature records only. Map detailed lifecycle states deterministically to
InIdeation,InBacklog,InProgress, orToBeReleasedwithout changing source state. - Populate Focus only from qualifying
InBacklog,InProgress, orToBeReleasedevidence. An empty Focus is correct when no item qualifies; state the exact missing approval, dependency, task-definition, or execution evidence. - Never create placeholder tasks to make Focus appear populated. A task needs a stable Architecture-owned ID, parent hierarchy, Feature implementation approval, and explicit exact-task human Focus admission.
Recommended structural validator
Add a repository validation script and include it in the main validation command. Check at least:
- Kanban plugin, search route, and top-level navigation order;
- dedicated sidebar containing Board then Focus;
- all four allowed Board columns;
- all known unfinished Epic/Feature IDs appear exactly as intended;
- no card has a terminal authoritative source status;
- Focus exposes only
InBacklog,InProgress, andToBeReleasedsections; - Focus preserves the exact-task human admission rule.
Avoid naïve substring checks when explanatory prose names excluded states. Validate headings or structured fields instead—for example, reject an ## InIdeation Focus section rather than rejecting every occurrence of the word InIdeation.
Verification and publication
- Run existing Scope and Architecture validators, the Kanban validator, TypeScript checks, the strict-link Docusaurus production build, and
git diff --check. - Push a review branch; do not merge autonomously.
- Open or update the existing PR against the integration branch; do not create a duplicate PR for the same review branch.
- Fetch the remote, verify the local and remote branch SHAs match, and confirm the worktree is clean.
- Read Board, Focus, sidebar, and config back from the exact remote commit. A deterministic local/remote comparison is:
git show origin/<BRANCH>:kanban/board.md | sha256sumversussha256sum kanban/board.md;- repeat for
kanban/focus.mdand any changed structural files.
- Read the PR remotely and confirm
state,merged,mergeable,head.sha, andbase.sha. Private Gitea repositories may return404to unauthenticated API requests; use an already configured runtime credential in memory without printing, exporting, or placing it on the command line. Treat a credentialed read as verification, not permission to merge. - Wait for an Actions run whose
head_shaexactly matches the PR head and requirestatus=completedplusconclusion=success; do not transfer CI results from another SHA. - Report paths, PR, commit, exact-head run ID, source message IDs, admission decisions, and unresolved gates.
Safe private-Gitea read pattern
For a private repository, resolve the active profile environment path, load only the configured Gitea token inside a short-lived process, and send it in an in-memory authorization header. Output only non-secret fields. Query:
/api/v1/repos/<OWNER>/<REPO>/pulls/<NUMBER>for PR state and exact head/base SHAs;/api/v1/repos/<OWNER>/<REPO>/actions/runs?limit=<N>for recent run IDs, head SHAs, status, conclusion, and event.
Never print the token, headers, environment file contents, exception request objects, or response bodies that may echo credentials. An unauthenticated 404 followed by a successful credentialed read means the repository is private; it is not evidence that the endpoint is absent.
Evidence pattern for an empty Focus
Record each ownership boundary explicitly:
- Scope: Epic/Feature state remains Proposed or otherwise outside active Focus.
- Architecture: no stable implementation task and/or no Approved-for-Implementation evidence.
- Kanban: no explicit human admission for an exact task.
- Delivery: no verified execution evidence.
- Releases: no verified release handoff.
This turns an empty Focus into a useful gate report rather than filler.