Przejdź do treści
Biblioteka skilli
DevOps i chmura · Automatyzacja

quality-gates

/quality-gates

Konfiguruje CI i higienę repozytorium: bramki formatowania, lintów, typów, testów, e2e, skanów sekretów i CodeQL przed scaleniem.

Repozytorium
ai-skill-ai ↗
Licencja
MIT
Ostatnia zmiana repozytorium
31.10.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
5
Skrypty
2
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 31.10.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co sprawdzić przed instalacją
  • 2 skrypty w paczce. Przejrzyj je przed instalacją, bo Claude może je uruchomić.

Skrypty: scripts/gate_run.py, scripts/repo_hygiene.py

Co robi i kiedy

Konfiguruje CI i higienę repozytorium: bramki formatowania, lintów, typów, testów, e2e, skanów sekretów i CodeQL przed scaleniem.

Oryginalny opis (EN)

Run the same verification loop on every change before anyone calls it done, with the CI and repo hygiene that enforce it. Use when the user asks to set up CI, add a GitHub Actions workflow, pin actions to SHAs, add branch protection, or wire up format, lint, typecheck, tests, build, e2e, accessibility, Lighthouse budget, secrets scan, dependency scan or CodeQL gates; when a change must pass gates before a push; or when a repo lacks README, LICENSE, SECURITY.md, CODEOWNERS, .editorconfig, a PR template or Conventional Commits. Runs the gates that exist in a fixed order, stops on the first failu

Jak działa

  1. When to use and when to stay off
  2. Non-negotiables
  3. Procedure
  4. Self-audit
  5. What this cannot do
Sekcje z nagłówków SKILL.md, w oryginale · 137 linii, 1 642 słów
Podgląd SKILL.md
---
name: quality-gates
description: Run the same verification loop on every change before anyone calls it done, with the CI and repo hygiene that enforce it. Use when the user asks to set up CI, add a GitHub Actions workflow, pin actions to SHAs, add branch protection, or wire up format, lint, typecheck, tests, build, e2e, accessibility, Lighthouse budget, secrets scan, dependency scan or CodeQL gates; when a change must pass gates before a push; or when a repo lacks README, LICENSE, SECURITY.md, CODEOWNERS, .editorconfig, a PR template or Conventional Commits. Runs the gates that exist in a fixed order, stops on the first failure, never installs anything, and pins every action to a full commit SHA with least privilege. Triggers on set up CI, GitHub Actions workflow, pin actions to SHA, branch protection, Lighthouse CI, gitleaks, osv-scanner, CodeQL, Dependabot, Renovate, commitlint. For local tools use devex-tooling. For what deserves a test use test-strategy. For versioning and rollout use release-manage. For a readiness audit use ship-audit.
license: MIT
metadata:
  version: 1.0.1
  suite: ai-skill
---

# Quality gates

Teams agree that work should be tested and reviewed, then let the definition of done drift per person
and per pull request. One change ships with a type error that the author did not run the checker to
see. The next ships a leaked token because no scan ran before the push. This skill corrects that by
making the gate a fixed, ordered list that runs the same way for every change, in the editor, in a
pre-push hook and in CI, with the CI copy as the one that blocks the merge.

## When to use and when to stay off

Run when the task is the verification loop itself or the repository plumbing that enforces it: wiring
the gates, writing the CI workflow, pinning actions, setting branch protection and rulesets, adding
the hygiene files, or checking a change against the gates before it is pushed.

Stay off, and route instead, when:

- The task is the local development environment: editor settings, formatter and linter choice, task runners, monorepo tooling, pre-commit framework setup. `devex-tooling` owns the tools; this skill owns the gate that runs them and the CI that blocks on them.
- The question is what deserves a test, what kind, and where the coverage should sit. `test-strategy` owns that. This skill runs whatever tests exist; it does not decide which tests should.
- The task is versioning, changelog, release notes, rollout or rollback. `release-manage` owns the release; this skill owns the gate that a release candidate passes on its way there.
- The task is a one-off readiness audit of work that already exists, scored against what the project is. `ship-audit` owns that assessment. This skill is the repeatable per-change loop, not the single judgement at the end.
- The task is the full WCAG pass the accessibility gate stands in for, with the manual screen-reader protocol. `accessibility` owns that; this skill runs the accessibility gate and blocks on it.
- The task is the quality of the code the gates run against, making it read as hand-written. `code-craft` owns that; this skill runs the checks, it does not judge craft.
- The work is hosting, environments or the deploy itself. `infra-deploy` owns that.
- The task is how commits, branches and merges are structured, or cleaning history. `git-workflow` owns that; this skill enforces the result in CI.

The user says "stop", "I've decided", or "just execute": comply at once and stay off for the rest of
the session unless asked again.

## Non-negotiables

These override everything else in this file.

1. Gates run in a fixed order and stop on the first failure: format, lint, typecheck, unit tests, build, e2e, accessibility, Lighthouse budgets, link check, bundle size, secrets scan, dependency scan, CodeQL, prose check, UI tells, SEO lint. A gate that does not exist in the project is skipped and named as skipped, never faked.
2. Never install anything to make a gate pass. `gate_run.py` detects and runs; it does not add dependencies, write lockfiles or edit config. Setup is a separate, stated step the user agrees to.
3. Every reusable action in a workflow is pinned to a full 40-character commit SHA, with the tag and the date checked in a trailing comment. A tag or branch reference (`@v4`, `@main`) is a finding, not a style choice.
4. Every job declares `permissions:` at the least privilege it needs, and the workflow sets a top-level `permissions: {}` default. A workflow with no `permissions:` block inherits write scopes and is a finding.
5. Dependency installs in CI are frozen: `npm ci`, `pnpm install --frozen-lockfile`, `uv sync --frozen`, or the lockfile-respecting equivalent. A plain `npm install` in CI is a finding.
6. `pull_request_target` runs with repository write access and secrets. It never checks out and runs code from the pull request head. Flag any `pull_request_target` workflow that checks out `github.event.pull_request.head`.
7. The gate budgets equal the project's own budgets. Lighthouse thresholds, bundle-size limits, coverage floors and accessibility rules are read from the repo's config, not softened to pass. A gate looser than the project's stated budget is reported as a gap, with the number.
8. First-time CodeQL enablement surfaces alerts in pre-existing code and opens review threads. Say this before turning it on, so the batch is expected and triaged per file rather than dismissed in bulk.
9. Secrets never enter a log or a command line. Tokens reach a step only through `secrets.*` into `env:`, and a scan that finds a real secret fails the gate and is handled as an incident, not an allowlist entry.

## Procedure

Read `references/ci-github-actions.md` for the full workflow, the Renovate and Dependabot configs and
the verified action SHAs. Read `references/repo-hygiene.md` for the required files, branch protection
and Conventional Commits. Boundaries with `devex-tooling`, `test-strategy`, `release-manage` and
`ship-audit` are set in the routing bullets above; read those skills first when the task crosses into
them.

### Step 1, inventory the gates the project already has

Run `scripts/gate_run.py --list` from the repository root. It detects the stack from `package.json`
scripts, `pyproject.toml`, `Cargo.toml` and `go.mod`, and reports which of the fixed-order gates it
can run and which are absent. Read the list before proposing anything: a gate the project does not
have yet is a decision to add, not a given.

### Step 2, run the gates in order and stop on the first failure

```
python3 scripts/gate_run.py
```

It runs each present gate in the fixed order, stops at the first non-zero exit, and prints a summary
table of pass, fail and skip with the command each gate ran. Paste the real table. A failure here is
the answer to "is this change done"; it is no until the table is clean. Use `--json` when a wrapping
script or a CI step needs to read the result.

### Step 3, check repository hygiene and CI safety

```
python3 scripts/repo_hygiene.py
```

It checks for the required files (README, LICENSE, SECURITY.md, CODEOWNERS, .editorconfig,
CONTRIBUTING, a pull-request template), and reads every workflow under `.github/workflows` for the
safety properties in non-negotiables 3 to 6: unpinned `uses:` lines, missing `permissions:`,
non-frozen installs and `pull_request_target` misuse. Each finding carries a severity. Fix high
findings before the next push.

### Step 4, write or repair the CI workflow

Use the workflow in `references/ci-github-actions.md` as the base. It runs the gates as jobs, pins
every action to a SHA with a dated comment, sets least-privilege `permissions:`, uses `concurrency`
to cancel superseded runs, installs with a frozen lockfile and caches by lockfile hash. Adapt the
jobs to the gates the project actually has; do not add a job for a gate that does not exist. Keep the
CI thresholds equal to the project budgets per non-negotiable 7.

### Step 5, set the branch protection and commit rules

Apply the protected-branch ruleset in `references/repo-hygiene.md`: require the gate checks to pass,
require review, require conversation resolution, require linear history, and forbid force pushes to
the default branch. Add commitlint with the Conventional Commits config so the history stays readable
and release tooling in `release-manage` can derive versions from it.

### Step 6, add dependency automation

Add Renovate or Dependabot from the configs in `references/ci-github-actions.md`, grouped and on a
schedule so updates arrive as reviewable batches rather than a flood. Both configs keep the SHA pins
and update the dated comment, so pinning does not freeze the repository on stale, vulnerable actions.

### Step 7, report what is gated and what is not

List which gates run, which are absent and why, and which CI safety findings remain open. Name the
gap where a gate is looser than the project budget, with the number. A pipeline that is green with
three gates missing is not the same as one that is green with all of them, and the report says which
one this is.

## Self-audit

- The gates ran in the fixed order and stopped on the first failure, and the pasted table shows pass, fail or skip for each with the command run.
- No gate was made to pass by installing, editing config or loosening a budget; any budget gap is reported with its number.
- Every `uses:` in every workflow is a full commit SHA with a tag and a date in a trailing comment; `repo_hygiene.py` reports zero unpinned lines.
- Every job has `permissions:` at least privilege and the workflow has a top-level `permissions: {}`.
- Every CI install is frozen, and no `pull_request_target` workflow checks out the pull request head.
- CodeQL was flagged as surfacing old-code alerts before it was enabled, and the first batch was triaged per file.
- The required hygiene files are present, branch protection and the Conventional Commits rule are set, and dependency automation is configured.
- Secrets appear only through `secrets.*` into `env:`, never in a log or a command line.

## What this cannot do

It cannot prove a change is correct, only that it passed the gates that exist. A green table with no
accessibility job says nothing about accessibility. The report names the gates that did not run.

It cannot run gates whose tools are not installed in the environment it runs in. `gate_run.py` detects
and runs; it does not install, so a missing tool is reported as a skipped gate, not a pass.

It cannot set branch protection or rulesets by itself. Those are changes to the repository's settings
on the forge, which the owner applies; this skill supplies the exact ruleset and the reason for each
rule.

It does not decide licence obligations for the dependencies a scan surfaces. When a dependency's
licence is copyleft or an unfamiliar licence appears in the tree, ask an intellectual property lawyer:
"Given that we distribute this software in this way, does including a dependency under this licence
create an obligation to release our own source, and if so over what scope?"
Pliki w paczce (5)
  • SKILL.md 11 KB
  • references/ci-github-actions.md 10 KB
  • references/repo-hygiene.md 5 KB
  • scripts/gate_run.py 12 KB
  • scripts/repo_hygiene.py 11 KB

Wersje

RepozytoriumWynikLicencja
Ta strona · devpilotX/ai-skill-ai100MIT
Kanevry/session-orchestrator100MIT
yonatangross/orchestkit100MIT
andymai/brepjs100Apache-2.0
matteocodogno/wellforge100MIT
AssassinFlash/b2b-seo-agent-engine100MIT
matteocodogno/wellforge100MIT
samplexbro/agentsmesh100MIT
samplexbro/agentsmesh100MIT

Migawka bazy z 13.11.2026 · wersja paczki a6d3f58664d0 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100go-ci
    Konfiguruje ciągłą integrację dla projektów Go: GitHub Actions, cache, golangci-lint, bramki testów i pokrycia, skanowanie podatności, CodeQL, gosec, Dependabot, przypinanie akcji i cele Makefile.
  • 100codeql
    Przewodnik po konfiguracji skanowania kodu CodeQL przez workflowy GitHub Actions i CLI CodeQL: pliki workflow, polecenia, wyjście SARIF i rozwiązywanie problemów z analizą.
  • 100ci-cd-pipeline-design
    Projektuje i naprawia pipeline'y CI/CD w GitHub Actions lub GitLab CI: układ etapów, cache, równoległość, bramki jakości, wymagane sprawdzenia i obsługa sekretów.
  • 90om-setup-ci
    Konfiguruje CI w aplikacji Open Mercato: audyt zależności, skan sekretów, SAST, lint, testy, obraz Docker i skany nocne.
  • 100ci-cd-quality-gates
    Projektuje lekkie bramki jakości CI: lint, poziomy testów, skany bezpieczeństwa i polityki merge, niezależnie od stosu technologicznego.
  • 100setup-quality-ci
    Generuje workflow GitHub Actions, który blokuje pull requesty przy błędach lintera Go, formatowania, nieaktualnego kodu generowanego i pokrycia testami poniżej 80 proc.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.