Input: Design documents from /specs/018-build-manifest/
Prerequisites: plan.md (required), spec.md (required), research.md, data-model.md, contracts/, quickstart.md
Tests: No automated tests requested. Verification via CLI smoke tests.
Organization: Tasks are grouped by user story to enable independent implementation and testing of each story.
- [P]: Can run in parallel (different files, no dependencies)
- [Story]: Which user story this task belongs to (e.g., US1, US2, US3)
- Include exact file paths in descriptions
Purpose: Create the build package structure and shared utilities.
- T001 (cc-mux-yuq.1) Create
internal/build/package directory - T002 (cc-mux-yuq.2) [P] Create
internal/build/manifest.gowith Manifest struct and YAML field tags matching thecc-deck-build.yamlschema (image, tools, sources, plugins, mcp, github_tools, settings sections) - T003 (cc-mux-yuq.3) [P] Create
internal/build/runtime.gowithDetectRuntime() stringfunction that checks for podman first, then docker, returns the binary name or error
Checkpoint: Build package exists with manifest model and runtime detection.
Purpose: Embed command and script assets into the Go binary.
- T004 (cc-mux-dwj.1) Create
internal/build/commands/directory with the 5 Claude Code command files:cc-deck.extract.md,cc-deck.plugin.md,cc-deck.mcp.md,cc-deck.containerfile.md,cc-deck.publish.md - T005 (cc-mux-dwj.2) [P] Create
internal/build/scripts/directory with helper scripts:validate-manifest.sh,update-manifest.sh - T006 (cc-mux-dwj.3) Create
internal/build/embed.gowithgo:embeddirectives forcommands/*andscripts/*directories, plus accessor functions - T007 (cc-mux-dwj.4) [P] Create
internal/build/templates/withcc-deck-build.yaml.tmplscaffold template (commented examples for each section)
Checkpoint: All embeddable assets exist. go build succeeds with embedded assets.
Goal: cc-deck build init <dir> creates a scaffolded build directory with manifest, commands, scripts, and gitignore.
Independent Test: Run cc-deck build init /tmp/test-build, verify directory structure, manifest validity, and command availability.
- T008 (cc-mux-t9z.1) [US1] Create
internal/build/init.gowithInitBuildDir(dir string, force bool) errorthat creates directory, extracts manifest template, commands, scripts, and generates.gitignore - T009 (cc-mux-t9z.2) [US1] Create
internal/cmd/build.gowith cobra parent commandbuildand subcommandinit(args:<dir>, flags:--force) - T010 (cc-mux-t9z.3) [US1] Register the
buildcommand incmd/cc-deck/main.go - T011 (cc-mux-t9z.4) [US1] Verify: run
cc-deck build init /tmp/test-build, confirm directory structure matches plan.md layout, manifest is valid YAML, commands are extracted
Checkpoint: cc-deck build init works. Build directory is ready for AI-driven population.
Goal: /cc-deck.extract analyzes repos and populates the manifest tools and sources sections.
Independent Test: Run /cc-deck.extract on a Go project, verify manifest is updated with Go version and source provenance.
- T012 (cc-mux-kn5.1) [US2] Write
cc-deck/internal/build/commands/cc-deck.extract.mdcommand file: YAML frontmatter + numbered steps for repository analysis, tool discovery, deduplication, conflict resolution, and manifest update - T013 (cc-mux-kn5.2) [US2] Write
cc-deck/internal/build/scripts/update-manifest.shhelper script for safe YAML section updates (tools, sources) without LLM touching raw YAML structure - T014 (cc-mux-kn5.3) [US2] Verify: init a build dir, open in Claude Code, run
/cc-deck.extracton the cc-deck Go project itself, confirm tools (Go, Rust) are detected and written to manifest
Checkpoint: Repository analysis works for Go and Rust projects.
Goal: /cc-deck.containerfile generates a valid, build-ready Containerfile from the manifest.
Independent Test: Populate manifest with known tools, run /cc-deck.containerfile, verify Containerfile builds successfully.
- T015 (cc-mux-ho5.1) [US3] Write
cc-deck/internal/build/commands/cc-deck.containerfile.mdcommand file: reads manifest, resolves free-form tools to install commands, generates layered Containerfile with DO NOT EDIT header, cc-deck self-embedding, Claude Code install, and github_tools downloads - T016 (cc-mux-ho5.2) [US3] Add manifest validation to
cc-deck/internal/build/manifest.go:Validate() errormethod checking required fields (version, image.name) and YAML structure - T017 (cc-mux-ho5.3) [US3] Verify: populate a manifest manually, run
/cc-deck.containerfile, confirm generated Containerfile is syntactically valid and includes all manifest entries
Checkpoint: Containerfile generation works for standard tool combinations.
Goal: cc-deck build <dir> builds the image, cc-deck push <dir> publishes it.
Independent Test: Given a valid Containerfile, run cc-deck build, verify image is produced with correct name/tag.
- T018 (cc-mux-6ed.1) [US4] Add
buildsubcommand logic incc-deck/internal/cmd/build.go: validate manifest, verify Containerfile exists, copy cc-deck binary to.build-context/, invoke container runtime with correct tags - T019 (cc-mux-6ed.2) [US4] Add
pushsubcommand incc-deck/internal/cmd/build.go: read image name/tag from manifest, invoke container runtime push - T020 (cc-mux-6ed.3) [US4] Add cc-deck self-embedding logic:
os.Executable()to find own binary, copy to.build-context/cc-deck, add.build-context/to.gitignore - T021 (cc-mux-6ed.4) [US4] Verify: init a build dir, generate a Containerfile (manually or via AI), run
cc-deck build, confirm image is created with correct name:tag
Checkpoint: Build and push commands work end-to-end.
Goal: /cc-deck.plugin and /cc-deck.mcp add entries to the manifest.
Independent Test: Run /cc-deck.plugin to add a plugin, verify manifest is updated.
- T022 (cc-mux-a31.1) [P] [US5] Write
cc-deck/internal/build/commands/cc-deck.plugin.mdcommand file: list current plugins, add from marketplace or git URL, update manifest - T023 (cc-mux-a31.2) [P] [US5] Write
cc-deck/internal/build/commands/cc-deck.mcp.mdcommand file: accept image reference, readcc-deck.mcp/*labels via container runtime inspect, auto-populate MCP entry, handle missing labels interactively - T024 (cc-mux-a31.3) [US5] Verify: run
/cc-deck.pluginto add "sdd", run/cc-deck.mcpwith an image reference, confirm manifest has both entries
Checkpoint: Plugin and MCP management works through AI commands.
Goal: cc-deck build verify smoke-tests the image, cc-deck build diff shows changes.
Independent Test: Build an image, run verify, confirm pass/fail report.
- T025 (cc-mux-9gm.1) [US6] Add
verifysubcommand incc-deck/internal/cmd/build.go: start container from built image, check tool availability, Claude Code startup, cc-deck version, report pass/fail - T026 (cc-mux-9gm.2) [US6] Add
diffsubcommand incc-deck/internal/cmd/build.go: compare manifest tools/plugins/mcp against last generated Containerfile, report added/removed/changed - T027 (cc-mux-9gm.3) [US6] Verify: build an image, run
cc-deck build verify, confirm it reports all tools present
Checkpoint: Verify and diff commands provide build confidence.
Purpose: Publish command, documentation, cleanup.
- T028 (cc-mux-e7g.1) [P] Write
cc-deck/internal/build/commands/cc-deck.publish.mdcommand file: convenience wrapper that runscc-deck buildthencc-deck push - T029 (cc-mux-e7g.2) [P] Write
cc-deck/internal/build/scripts/validate-manifest.shhelper that validates manifest YAML schema (called by commands before updates) - T030 (cc-mux-e7g.3) Update
cc-deck/internal/build/templates/cc-deck-build.yaml.tmplwith final commented examples reflecting all sections from data-model.md - T031 (cc-mux-e7g.4) Add
--install-zellijflag tocc-deck plugin installincc-deck/internal/cmd/plugin.gofor downloading and installing the matching Zellij binary inside containers
- Setup (Phase 1): No dependencies, start immediately
- Foundational (Phase 2): Depends on Phase 1 (needs package directory)
- User Story 1 (Phase 3): Depends on Phase 2 (needs embedded assets)
- User Story 2 (Phase 4): Depends on US1 (needs initialized build directory)
- User Story 3 (Phase 5): Depends on US2 (needs populated manifest)
- User Story 4 (Phase 6): Depends on US3 (needs Containerfile)
- User Story 5 (Phase 7): Depends on US1 (needs build directory), independent of US2-4
- User Story 6 (Phase 8): Depends on US4 (needs built image)
- Polish (Phase 9): Can start after US1
- US1 (P1): Blocked by Foundational only
- US2 (P1): Depends on US1
- US3 (P1): Depends on US2 (or manual manifest population)
- US4 (P2): Depends on US3
- US5 (P2): Depends on US1 only (independent of US2-4)
- US6 (P3): Depends on US4
- T002 and T003 can run in parallel (different files)
- T004 and T005 can run in parallel (different directories)
- T022 and T023 can run in parallel (different command files)
- T028 and T029 can run in parallel (different files)
- Complete Phases 1-2: Setup + Foundational
- Complete Phase 3: US1 (build init)
- Complete Phase 4: US2 (extract)
- Complete Phase 5: US3 (containerfile)
- STOP and VALIDATE: Init → extract → containerfile → manual build
- This gives a working end-to-end flow
- Setup + Foundational + US1 →
cc-deck build initworks (MVP entry point) - Add US2 → Repository analysis works
- Add US3 → Containerfile generation works
- Add US4 →
cc-deck build+pushworks (full CLI flow) - Add US5 → Plugin and MCP management
- Add US6 → Verify and diff commands
- [P] tasks = different files, no dependencies
- [Story] label maps task to specific user story for traceability
- Claude Code commands (
.mdfiles) are the primary deliverable for US2, US3, US5 - CLI commands (Go code) are the primary deliverable for US1, US4, US6
- All commands and scripts are embedded in the Go binary via
go:embed - Commit after each task or logical group