Index of every page on this site: llms.txt
All skills
Run it yourself

Audits a repository's GitHub Actions workflows for CI optimization opportunities — missing caches, redundant setup, sleep-based readiness, long test jobs without sharding, full-history checkout, dead env vars, build-cache misconfig, and ~60 more patterns across caching, redundancy, parallelization, conditional execution, trigger scope, and hidden failures. Use when: (1) analyzing a repo's CI for optimization opportunities, (2) producing a prioritized report with measured wall-clock and runner-minute savings, (3) re-auditing after upstream CI changes. Do not trigger for: general CI setup help, writing new workflows from scratch, non-GitHub-Actions CI systems, or security/posture audits — use `ci-secure` for those.

Use this Skill: https://skilld.dev/gh/starslingdev/skills/ci-speedup

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencespatternsopt105-reuse-local-hook-work-by-input.md

≈797 tokens on demand. Your agent reads this file only when SKILL.md points to it.

OPT105 — Local Hook Work Is Repeated in Pull-Request CI

TL;DR: A local Git hook runs the same resolved type-check, lint, test, or build command that pull-request CI runs again from scratch. The repeated CI steps are a measured share of the job. Keep CI authoritative, but make its second proof cheap by reusing work keyed to the inputs.

Detection heuristic: read static hook configuration from .husky/, .githooks/, lefthook.yml, .pre-commit-config.yaml, or simple-git-hooks in package.json. Resolve package scripts on both the hook and workflow sides, then match literal leaf commands. Admit a finding only when the matched CI steps have jobs-API timestamps, total at least 20 seconds at p50, and account for at least 15% of the pull-request job. A missing, unreadable, dynamic, or different hook stays quiet.

Fix recipe — input-keyed reuse is the default: make the CI rerun cheap without trusting a claim from a developer machine. Depending on the matched work, use tsc --incremental with a cached .tsbuildinfo, eslint --cache with its cache file persisted, changed-file test selection such as --changedSince, or a remote task cache such as Turborepo or Nx. Key reuse on the source tree, lockfile, configuration, and tool versions. A cache miss or changed input still performs the full check in CI. When actions/cache stores local tool-result state, use a rolling primary key such as <tool>-<os>-<lockfile-hash>-${{ github.sha }} and a matching restore-keys prefix such as <tool>-<os>-<lockfile-hash>-; set a cache budget and retention policy so superseded results do not grow without bound.

Optional, owner-approved alternative — trailer skip: a hook may record a commit trailer naming the checks it ran, but this is opt-in because it changes the trust model. Bind the claim to the commit's tree hash, lockfile, and tool versions so an amend, rebase, dependency change, or tool change invalidates it. Honor it only for branches in the same repository, never pull requests from a fork. Keep the full suite on the merge queue or, when there is no merge queue, the default branch, so the merge gate still proves the work. State plainly that a trailer can be written by hand and a hook can be bypassed with --no-verify: accepting it is a trust decision for the repository owner, not a cache hit.

Sizing: wall-clock is the matched steps' measured p50, bounded by the affected job's critical-path headroom. Runner-minutes are the same measured step compute scaled by observed pull-request run volume and capped at the affected job's measured completed-run compute. Both are ceilings until the chosen input-keyed reuse is measured after adoption; the trailer alternative gets no credit on the merge-gate run where the full suite remains mandatory.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 alert2d3 checks · Risk SAFE
  • Gen Agent Trust Hub2d

    The skill is a robust CI optimization tool that audits GitHub Actions workflows. It identifies performance bottlenecks using deterministic logic and provides analysis of job logs. While it processes untrusted log data, it includes strong defensive instructions to mitigate indirect prompt injection. A minor best-practice issue regarding unsafe YAML loading was identified in a utility script.

  • Socket2d

    No alerts

  • Snyk2d

    Risk: CRITICAL · 2 issues

Signed by skilld at 9a84115. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 16 hours ago.

Activeupdated yesterday

README badge

README badge for starslingdev/skills/ci-speedup