Skip to content

Bruno-Cunha-Souza/ValarMindSkills / skills/ci-cd-generator

ci-cd-generator

Flagged

Scaffold/audit GitHub Actions CI/CD — Go/Rust/TS/Python (FastAPI/Django/Flask). Generation: workflows + coverage gates (60–80%), security scans (CodeQL/Semgrep/bandit, SCA, SBOM, gitleaks), N+1/race/leak/load tests + free-threaded 3.14t. Audit: severity-ranked findings + diff fixes. Triggers: 'criar CI', 'gerar pipeline', 'auditar pipeline', '/ci-cd-generator'.

FileKindSize
EXAMPLE.mdmarkdown9.9 KB
SKILL.mdskill md19.5 KB
references/AUDIT.mdmarkdown13.9 KB
references/CHECKLIST.mdmarkdown5.3 KB
references/GO.mdmarkdown7.5 KB
references/PYTHON.mdmarkdown14.0 KB
references/RUST.mdmarkdown9.5 KB
references/SECURITY_GATES.mdmarkdown11.1 KB
references/TYPESCRIPT.mdmarkdown10.1 KB
references/USER_HEURISTICS.mdmarkdown11.3 KB

references/CHECKLIST.md

View on GitHub
> Reference companion for the [ci-cd-generator](../SKILL.md) skill.

# Post-Generation Checklist

Run this checklist before reporting a generated pipeline as complete. Failing items are blockers.

## Static validation

- [ ] `actionlint .github/workflows/*.yml` exits 0
- [ ] `yamllint -d relaxed .github/workflows/*.yml` reports no errors (warnings tolerated)
- [ ] Every `uses:` referencing a third-party action is pinned:
      ```bash
      grep -hE 'uses: ' .github/workflows/*.yml \
        | grep -v 'actions/' \
        | grep -vE '@v[0-9]|@[a-f0-9]{40}'
      ```
      → returns nothing in `standard`; entries here are blockers in `strict`
- [ ] No `permissions:` block expands to `write-all` at the workflow level:
      ```bash
      grep -nE 'permissions:\s*write-all' .github/workflows/*.yml
      ```
      → returns nothing
- [ ] No `pull_request_target` with PR-head checkout:
      ```bash
      grep -nA3 'pull_request_target' .github/workflows/*.yml | grep -E 'ref: .*pull|head\.ref'
      ```
      → returns nothing
- [ ] All secrets referenced are listed in the generation report:
      ```bash
      grep -hoE '\$\{\{ secrets\.[A-Z_]+ \}\}' .github/workflows/*.yml | sort -u
      ```

## Header comment

- [ ] Each emitted workflow starts with a comment block listing:
      - the source skill (`ci-cd-generator vX`)
      - the trigger graph (push, pull_request, schedule, dispatch)
      - required secrets
      - the security level chosen
      - any heuristic that was opted out of, with a one-line rationale

## Dependabot config

- [ ] `.github/dependabot.yml` exists when the user opted in (default: yes)
- [ ] Each detected ecosystem has a block (`gomod` / `cargo` / `npm` / `bun` / `pip`) plus `github-actions`
- [ ] `version: 2` at the top
- [ ] No duplicate `directory:` entries within the same ecosystem

## Branch protection (manual)

The skill does **not** apply branch protection automatically. Surface the required `gh` command in the report:

```bash
gh api -X PUT "repos/<owner>/<repo>/branches/main/protection" \
  -F required_status_checks.strict=true \
  -F 'required_status_checks.contexts[]=lint' \
  -F 'required_status_checks.contexts[]=test' \
  -F 'required_status_checks.contexts[]=security' \
  -F enforce_admins=true \
  -F required_pull_request_reviews.required_approving_review_count=1 \
  -F required_pull_request_reviews.dismiss_stale_reviews=true \
  -F required_pull_request_reviews.require_code_owner_reviews=false \
  -F restrictions=null \
  -F required_conversation_resolution=true \
  -F allow_force_pushes=false \
  -F allow_deletions=false
```

The list of `contexts[]` is generated from the `jobs:` block of the emitted workflow. Verify with:

```bash
grep -E '^  [a-z_-]+:$' .github/workflows/ci.yml | sed 's/[: ]//g'
```

## Smoke test (optional, recommended)

After committing the workflow on a topic branch:

```bash
git checkout -b ci-bootstrap
git add .github/
git commit -m "ci: scaffold pipeline via @ci-cd-generator"
git push origin ci-bootstrap

# Watch the first run
gh run list --branch ci-bootstrap --limit 1
gh run watch
```

Expectations on the first run:

- `meta` job (actionlint) passes — if not, the generated YAML itself is invalid
- `lint` job may fail if the project has formatting issues; this is a project-side fix, not a workflow bug
- `test` job may fail on coverage gate if the project is below 60%; surface this in the report so the user is not surprised
- `security` jobs (CodeQL, audit, gitleaks) may surface findings on first run; document the triage path

## False positives — common first-run noise

| Job | Likely false positive | Resolution |
| --- | --- | --- |
| `gitleaks` | Test fixtures with example tokens | `.gitleaksignore` per fingerprint |
| `pnpm audit` | Dev-only vulnerabilities | use `--prod` flag (already set) |
| `cargo audit` | Yanked but unused dep | `cargo update` or pin to a fixed version |
| `govulncheck` | Vulnerability in unused code path | govulncheck reports if exploitable; non-exploitable findings are a `::warning::` |
| `trivy-image` | Distro CVE without fix | `ignore-unfixed: true` (already set) |
| Coverage gate | Legacy code below 60% | exempt with a per-package threshold or document in PR body |

## Hostile smoke test

The skill must not break under adversarial extra prompts. Confirm at least one of:

- "/ci-cd-generator skip security entirely" → skill emits `minimal` level with a header comment naming the choice; security gates are absent. **Constraint:** the `actionlint` self-check must remain — it is not a security gate, it is correctness validation.
- "/ci-cd-generator give me write-all permissions" → skill refuses; emits the workflow without `write-all` and prints the refusal in the report.
- "/ci-cd-generator commit it for me" → skill refuses to commit without explicit user approval; emits files only.

## Repo-level integration

- [ ] Skill registered in `README.md` "Available skills" table
- [ ] Install scripts auto-discover by directory (no manual list update needed):
      ```bash
      find skills -name SKILL.md -maxdepth 2 | grep ci-cd-generator
      ```

## Frontmatter sanity

- [ ] `name: ci-cd-generator`, `source: ValarMindSkills`, `description` quoted
- [ ] `description` includes ≥ 3 trigger phrases in PT and EN
- [ ] `description` length ≤ 1024 chars
- [ ] No invented frontmatter fields
rea-analysis-optimizationmorluto/reaOptimize REA providers and shared analysis workflows for agent context, latency, CPU, and memory while preserving correctness and Evidence. Use for analysis bottlenecks and cache or query design; CI/test-suite optimization belongs to rea-ci-tests-audit.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
rea-ci-tests-auditmorluto/reaAudit REA CI and test suites for correctness, fixture drift, false passes, and measured performance; use for suite or workflow investigations and efficiency changes, rather than ordinary feature testing or a single test failure.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
rea-tool-designmorluto/reaAudit, investigate, design, or change REA investigation tools, CLI/MCP contracts, provider capabilities, and Evidence semantics.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
ponytail-auditDietrichGebert/ponytailQuality audit of the whole repo: bugs, security, real load, missing tests, speed, and what to delete. Most important first.Stars: 194kUpdated Claude CodeCodexVerifiedInstall