agentleFS
dvy1987dvy1987/agent-loom/.agents/skills/ci-cd-and-automation/SKILL.md

ci-cd-and-automation

Skill4 starsChanged 3 months agoMITView on GitHub

Design and implement CI/CD pipelines and automation — fast checks on every PR, safe releases, and repeatable workflows. Load when setting up GitHub Actions (or similar), adding pre-merge gates, automating releases, or the user asks "add CI", "set up workflows", "automate checks", "CD pipeline". Not for one-off local scripts (use task-specific tooling).

70 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use deprecation-and-migration, constraint-driven-development and 8 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • HK-hubSkill

    deprecation-and-migration

    Manages deprecation and migration. Use when removing old systems, APIs, or features. Use when migrating users from one implementation to another. Use when deciding whether to maintain or sunset existing code.

    Also in 39 projects that use this

  • MrCipherSmithSkill

    constraint-driven-development

    Use when a project needs a persistent, measurable quality bar — starting a project without documented standards, 'set up constraints', or when coverage/perf/a11y thresholds get re-debated per-PR. Produces CONSTRAINTS.md with enforceable numbers, ratchets, and a guard against silent weakening. NOT for throwaway prototypes or a one-off CI setup.

    Also in 14 projects that use this

  • HK-hubSkill

    observability-and-instrumentation

    Instruments code so production behavior is visible and diagnosable. Use when adding logging, metrics, tracing, or alerting. Use when shipping any feature that runs in production and you need evidence it works. Use when production issues are reported but you can't tell what happened from the available data.

    Also in 28 projects that use this

  • seikaikyoSkill

    doubt-driven-development

    對非平凡決策啟動新鮮 context 對抗審查(找碴不背書),在修正還便宜的時候抓出錯誤方向。適用:高風險改動(production、資安敏感邏輯、不可逆操作)、不熟的程式碼、要宣稱「這樣是安全的 / 可行的」之前。機械性操作與一行修改不適用。

    Also in 31 projects that use this

  • seikaikyoSkill

    interview-me

    需求不明時的意圖萃取訪談:一次一題、每題附上自己的猜測、聽出「真正想要 vs 覺得應該要」,直到能預測使用者反應(約 95% 信心)才動工。適用:需求缺少對象 / 動機 / 成功標準 / 約束,或使用者點名「訪談我」「先確認一下」「我們確定嗎」。明確自足的指示、純資訊查詢、機械性操作不適用。

    Also in 30 projects that use this

  • AnasX7Skill

    minimalist-ui

    Clean editorial-style interfaces. Warm monochrome palette, typographic contrast, flat bento grids, muted pastels. No gradients, no heavy shadows.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

9 rules. 0 are common, 8 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 67 edited versions we read keep these.

  • 8

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Prefer fast PR checks (minutes) over heavy pipelines that nobody trusts.

    line 26
  2. Distinctive:

    Never store secrets in repo.

    line 28
  3. Distinctive:

    Add automation only when it has a clear owner and a failure mode plan.

    line 30
  4. Distinctive:

    Add concurrency cancellation on PR branches

    line 54
  5. Distinctive:

    Use env vars from secret store

    line 59
  6. Distinctive:

    Avoid broad “write-all” permissions on default branch workflows

    line 61
  7. Distinctive:

    Run formatter on changed files (if you accept auto-fixes)

    line 67
  8. Very specific:

    Create .github/workflows/ci.yml with node-version pinned, npm cache, npm ci, npm run lint, npm test, npm run build, concurrency cancel.

    line 128
  9. Distinctive:

    No changes — citation audit passed.

    line 154

“Common” is measured: kept by at least 6 in 10 of the 67 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

CI/CD and Automation

You create a pipeline that is fast, deterministic, and protective: it runs the right checks automatically, fails loudly, and makes shipping boring.

Hard Rules

  • Prefer fast PR checks (minutes) over heavy pipelines that nobody trusts.
  • Fail on lint/test/typecheck/build before merge; keep steps deterministic.
  • Never store secrets in repo; use platform secret stores and least privilege.
  • Make workflows cache-aware and concurrency-safe (cancel superseded runs).
  • Add automation only when it has a clear owner and a failure mode plan.

Workflow

Step 1 — Define lifecycle and artifacts

Write:

  • Target events: PR, main push, tag, manual dispatch
  • Required gates: lint, unit, integration, build, security scan (if available)
  • Release artifact: npm package, container, binary, docs site, or “none”

Step 2 — Choose the minimum viable pipeline

Start with:

  • PR workflow: checkout → setup runtime → install deps → cache → lint/typecheck → tests → build
  • Main workflow: re-run critical checks + publish artifact (optional)

Step 3 — Make it reliable

  • Pin runtime versions (Node/Python/etc.)
  • Use lockfiles
  • Cache dependencies
  • Add concurrency cancellation on PR branches
  • Split slow suites into separate jobs only when needed

Step 4 — Secrets and permissions

  • Use env vars from secret store
  • Minimize token permissions (read-only unless publishing)
  • Avoid broad “write-all” permissions on default branch workflows

Step 5 — Add automation hooks (only if they pay rent)

Examples:

  • Auto-label PRs
  • Run formatter on changed files (if you accept auto-fixes)
  • Generate changelog on release tag

Step 6 — Verification

  • Trigger PR workflow on a small change; ensure duration is acceptable
  • Confirm failing checks block merge (branch protection)
  • Confirm secrets are not echoed in logs

When NOT to use

  • Tiny repos where CI cost exceeds value (prototype stage) unless the user explicitly wants it
  • Complex deployment platforms without access (require infra context first)

Gotchas

  • “Green CI” that doesn’t match local commands becomes ignored.
  • Unpinned runtimes cause flakey builds over time.
  • Missing branch protections makes CI advisory-only.
  • Long pipelines encourage skipping checks; keep PR path fast.

Common Rationalizations

ExcuseReality
"We don’t need CI yet"CI is cheapest when the repo is small; add the PR gates early.
"Let’s add every check"Overbuilt CI becomes slow and ignored; start minimal and expand on evidence.
"Caching is premature optimization"Without caching, CI becomes slow and gets bypassed.
"We’ll add branch protection later"CI without enforcement is a suggestion, not a gate.
"We can just use a PAT"PATs are high-risk; use least-privilege tokens and secret stores.

Output Format

## CI/CD plan — [repo]

Events: [PR/main/tag/manual]
Jobs: [list]
Runtime pinned: [yes/no]
Caching: [what]
Secrets: [needed + where stored]
Protections: [branch protections summary]
Verification: [how to prove it works]

Examples

<examples> <example> <input>“Add CI to a TypeScript repo.”</input> <output> Create `.github/workflows/ci.yml` with node-version pinned, npm cache, `npm ci`, `npm run lint`, `npm test`, `npm run build`, concurrency cancel. Add branch protection requiring the workflow. </output> </example> </examples>

Verification

  • PR checks run on a sample PR and complete in an acceptable time
  • Lint/tests/build are deterministic and match documented local commands
  • Caching is enabled where appropriate
  • Secrets are stored in the platform secret store (not repo)
  • Branch protections enforce required checks (or explicitly deferred)

Red Flags

  • CI commands diverge from local lint/test/build scripts
  • Runtimes and action versions left unpinned
  • Branch protection missing — CI is advisory only
  • Secrets committed or inlined in workflow YAML

Prune Log

Last pruned: 2026-07-04

  • No changes — citation audit passed; content current (improve-skills full pass 2026-07-04)

Impact Report

Repo: [name] | Workflows: N | Gates: [list]
Runtime pinned: [yes/no] | Cache: [yes/no]
Protections: [enforced/deferred]

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.