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.

referencespatternsopt36-cron-schedule-too-frequent.md

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

OPT36 — Cron Schedule Too Frequent

TL;DR: A scheduled (cron) workflow runs more often than it needs to, or reruns scanner categories whose explicitly defined inputs have not changed.

Anti-pattern: Cron-triggered workflows running more frequently than necessary for their purpose. Common examples: cleanup/triage jobs running every 5 minutes when every 15-60 minutes would suffice, or scheduled builds running hourly when daily is adequate.

Detection heuristic:

# Find cron schedules and classify frequency
grep -rn 'cron:' .github/workflows/ | while read line; do
  file=$(echo "$line" | cut -d: -f1)
  cron=$(echo "$line" | grep -oP "'[^']+'" | tr -d "'")
  min_field=$(echo "$cron" | awk '{print $1}')
  # Flag schedules running more than 4x/hour
  if echo "$min_field" | grep -qP '^\*/[1-9]$|^\*/1[0-4]$'; then
    echo "OPT36 hit: $file runs every $(echo $min_field | tr -d '*/')min — verify frequency is justified"
  fi
done

Fix: Increase the cron interval to match the actual operational need. For issue cleanup/triage bots: */15 or */30 is typically sufficient. For scheduled builds: daily or every 6 hours. Document the rationale for the chosen frequency.

For a multi-category scanner, keep a separate last-successful commit for each category. Before the next scheduled scan, compare that category's current input paths with its own baseline and skip it only when the complete comparison contains no relevant change. If the baseline, compare result, exclusion syntax, or changed-file list is unavailable or incomplete, run the scan. Keep pull-request and manual scans unchanged. This fail-open recipe preserves coverage while avoiding work whose inputs are proven unchanged.

Real-world example (mastra): PR #14432 changed spam issue cleanup from every 5 minutes (*/5 * * * *) to every 15 minutes — the job rarely finds new spam within a 5-minute window.

Public evidence: openclaw/openclaw#191805 (API requests per tick went from 21 to 3).

Tier-2 render note: When run history shows consecutive event=schedule runs on the same head_sha, or a complete compare between consecutive scheduled runs touches only the scanner's explicit inline paths-ignore (every job a CodeQL category with resolvable interpreted languages and the same inline exclusions, a forward ahead/identical compare, a successful previous scan, renames counted at both paths, and workflow/CodeQL-config/local-action paths always relevant), OPT36 can promote as measured schedule burn. The finding must size only the schedule-event subset, carry sizing_basis=measured, price from successful schedule-event job timings only, stamp tier2_run_subset_events: ["schedule"], and carry a non_pr_event certificate. The measured finding states a signed runner-minute saving and scales one sampled schedule-run population to the schedule's 30-day volume. A changed relevant path, an unreadable/truncated compare, or exclusions the audit cannot classify retains the scan. Static cron-frequency hits without measured redundant run evidence remain modeled residual findings in "Also noticed"; a matching static row on a measured workflow is superseded by the measured finding.


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