kramme-cc-workflow/skills/kramme:pr:design-pipeline/SKILL.md
Design a CI/CD pipeline with quality gates, a <10-minute budget, feature-flag lifecycle, and an exit checklist. Use when adding a new CI pipeline, changing gate configuration, or planning a rollout for a new service. Complementary to kramme:pr:fix-ci (which fixes failures in an existing pipeline). Covers gate ordering, secrets storage, branch protection, rollback mechanism, and staged-rollout guardrails — not a rollout-execution runbook.
npx skillsauth add abildtoft/kramme-cc-workflow kramme:pr:design-pipelineInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Design a CI/CD pipeline at author time, before failures happen. This skill is the complement to kramme:pr:fix-ci: that one fixes a broken pipeline; this one designs a pipeline worth having.
Use this when:
Do NOT use this when:
kramme:pr:fix-ci.Before recommending any gate, declare what you detected about the repository. Emit a STACK DETECTED marker with:
Example:
STACK DETECTED: GitHub Actions; TypeScript + Python; pnpm-lock.yaml and uv.lock;
existing .github/workflows/ci.yml runs lint + unit only, no types/integration/audit/build.
If any of these are ambiguous (multiple package managers, no clear CI file, mixed lockfiles), emit CONFUSION and ask before proceeding. Gate recommendations that ignore the stack are noise.
"A bug caught in linting costs minutes; the same bug caught in production costs hours."
"No gate can be skipped. If lint fails, fix lint — don't disable the rule."
"Smaller batches and more frequent releases reduce risk, not increase it."
These three together dictate the design:
Default order, fastest first:
The ordering matters because fast-fail saves contributor time. A broken lint should cancel the rest of the pipeline in under a minute, not block at integration-test time after eight minutes of compute.
For gates already present in the repo, annotate which already exist and which are new. Do not silently replace existing gates — explicitly name every delta and confirm with the user.
Target: under 10 minutes wall-clock, fresh PR, cold cache.
If the pipeline is over 10 minutes or trending there, pick from:
A gate that still can't fit the budget is a signal to split, not remove: keep a blocking PR slice that covers the same risk on every PR, then run the extended suite in the merge queue, on push to main, or nightly as a backstop. Nightly-only is never enough for a gate that protects merge readiness.
Every feature behind a flag has a lifecycle. The common failure is skipping the last step.
Step 5 is the one teams skip. A dead flag that still exists in code is a rollback trap: someone reads the flag as live, reasons about both branches, or reintroduces the gated-off path because it "looks intentional." Every flag's design must name its removal criteria up-front (e.g., "remove after 30 days at 100% with zero rollback events").
If the user proposes a flag without a removal plan, emit MISSING REQUIREMENT and require one.
For the canary → full-rollout sequence, short summary. If the design requires more than the four bullets below, that work is out of scope for this skill; stop and call it out as separate rollout-runbook work.
.env files (gitignore is a convention, not a boundary). Not in CI-level env vars without masking. Never echoed in logs.A pipeline is ready to land when every box is checked:
Use these markers verbatim (uppercase, no decoration), one marker per line. They are a plugin-wide convention for Addy-ported skills.
UNVERIFIED: I couldn't confirm the integration tests actually exercise the DB — they may be mocking it.NOTICED BUT NOT TOUCHING: the release workflow mixes secrets into build output; worth a separate pass.CONFUSION: the repo has both package-lock.json and pnpm-lock.yaml; which is authoritative?MISSING REQUIREMENT: no stated rollback target; what's the maximum acceptable downtime?Watch for these excuses — they signal the design is about to regress:
| Excuse | Reality |
| --- | --- |
| "We can skip the audit gate for speed." | Audit cost is one-time to set up and seconds to run with caching. The cost of a shipped vulnerability is unbounded. |
| "Secrets in .env are fine, it's gitignored." | Gitignore is a convention, not a boundary. One git add -A and secrets are in history. Use a secrets manager. |
| "We'll remove the flag later." | "Later" is where dead flags live forever. Every flag ships with a named removal criterion or it doesn't ship. |
| "Integration tests are slow, skip them on PR." | Skipping is how regressions ship. Parallelize, shard, or gate-per-change — don't remove the gate. |
| "We don't need branch protection, the team is small." | Small teams make small mistakes at high velocity. Branch protection costs nothing and catches the one 2am push that otherwise lands unreviewed. |
| "The pipeline is 18 minutes but nobody complains." | People route around slow pipelines — smaller PRs get batched, tests get skipped locally, --no-verify creeps in. The complaint surfaces as erosion, not a bug report. |
If any of these are true, pause and re-design before recommending the pipeline:
STACK DETECTED first.Before handing the design off, confirm:
STACK DETECTED was emitted and names platform, language, package manager, and existing pipeline state.UNVERIFIED, CONFUSION, or MISSING REQUIREMENT marker is resolved or explicitly deferred by the user.tools
Requires Linear MCP. Implements one Linear issue end to end, selects applicable code-review, convention, and PR-refactor gates, runs them to bounded convergence, verifies, and optionally opens the PR and iterates on CI and review feedback until green. Use when the user wants a single Linear issue taken from implementation through a clean Pull Request. Not for implementation-only work, SIW-tracked issues, stacked PRs, existing PR updates, or post-merge rollout.
development
Reviews PR and local changes for convention drift and overcaution against documented rules and mined peer-file practice. Use for new patterns, dependencies, abstractions, or defensive complexity that departs from established practice; every finding cites evidence. Supports --inline. Not for general code quality (use kramme:pr:code-review) or spec review (use kramme:siw:spec-audit --team).
testing
Charts huge or foggy initiatives into a local `.context` decision map and resolves one typed frontier ticket per session until the work is ready for SIW or another execution workflow. Use when the route to a destination cannot fit in one agent session or parallel workspaces need coordinated planning state. Not for clear specs, ordinary issue decomposition, implementation, or Linear-native tracking.
development
Investigates a question against primary sources and saves one cited Markdown artifact. Use for reading legwork: official docs/API facts, source-code or spec checks, standards, and first-party service behavior before planning or implementation. Not for making product or architecture decisions, implementing code, broad web search, secondary blog summaries, or uncited answers.