返回顶部
g

github-actions-trigger-health-audit触发健康审计

Audit GitHub Actions run health by trigger event and workflow so flaky or noisy automation sources are easy to prioritize.

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
297
下载量
免费
免费
0
收藏
概述
安装方式
版本历史

github-actions-trigger-health-audit

GitHub Actions 触发事件健康审计

使用此技能可找出哪些 GitHub Actions 触发事件导致了最高的失败率。

技能功能

  • - 读取一个或多个 GitHub Actions 运行 JSON 导出文件
  • 按仓库 + 事件 + 工作流对运行进行分组
  • 计算失败/取消/超时率及平均运行时间
  • 基于可配置的失败率阈值标记警告/严重热点
  • 支持对仓库、工作流和事件使用正则包含/排除过滤器
  • 输出文本或 JSON 格式,用于仪表盘和自动化门控

输入参数

可选参数:
  • - RUNGLOB(默认值:artifacts/github-actions/*.json)
  • TOPN(默认值:20)
  • OUTPUTFORMAT(text 或 json,默认值:text)
  • MINRUNS(默认值:2)— 跳过样本量过小的分组
  • FAILWARNPERCENT(默认值:20)
  • FAILCRITICALPERCENT(默认值:40)
  • FAILONCRITICAL(0 或 1,默认值:0)
  • WORKFLOWMATCH(正则表达式,可选)
  • WORKFLOWEXCLUDE(正则表达式,可选)
  • EVENTMATCH(正则表达式,可选)
  • EVENTEXCLUDE(正则表达式,可选)
  • REPOMATCH(正则表达式,可选)
  • REPOEXCLUDE(正则表达式,可选)

收集运行 JSON

bash
gh run view --json databaseId,workflowName,event,conclusion,headBranch,headSha,createdAt,updatedAt,startedAt,url,repository \
> artifacts/github-actions/run-.json

运行

文本报告:

bash
RUN_GLOB=artifacts/github-actions/*.json \
MIN_RUNS=3 \
FAILWARNPERCENT=25 \
FAILCRITICALPERCENT=50 \
bash skills/github-actions-trigger-health-audit/scripts/trigger-health-audit.sh

带失败门控的 JSON 输出:

bash
RUN_GLOB=artifacts/github-actions/*.json \
OUTPUT_FORMAT=json \
FAILONCRITICAL=1 \
bash skills/github-actions-trigger-health-audit/scripts/trigger-health-audit.sh

使用捆绑测试数据运行:

bash
RUN_GLOB=skills/github-actions-trigger-health-audit/fixtures/*.json \
bash skills/github-actions-trigger-health-audit/scripts/trigger-health-audit.sh

输出约定

  • - 报告模式下退出码为 0(默认)
  • 当 FAILONCRITICAL=1 且任意分组达到严重阈值时,退出码为 1
  • 文本模式打印摘要 + 排名后的触发事件健康热点
  • JSON 模式打印摘要 + 分组指标 + 严重分组详情

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 github-actions-trigger-health-audit-1776198941 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 github-actions-trigger-health-audit-1776198941 技能

通过命令行安装

skillhub install github-actions-trigger-health-audit-1776198941

下载

⬇ 下载 github-actions-trigger-health-audit v1.0.0(免费)

文件大小: 5.03 KB | 发布时间: 2026-4-15 12:49

v1.0.0 最新 2026-4-15 12:49
Initial release of GitHub Actions Trigger Health Audit.

- Audits GitHub Actions runs, grouping by repository, event, and workflow.
- Calculates failure, cancel, and timeout rates, plus average runtime.
- Flags warning and critical hotspots based on configurable thresholds.
- Supports include/exclude regex filters for repo, workflow, and event.
- Offers text and JSON output for dashboards and automation gating.
- Customizable thresholds and fail conditions for automation integration.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部