GitHub 部署变更审计
github-deployment-change-audit
审计 GitHub 仓库近期的部署情况,汇总功能性的合并变更,排除仅修改文档的 PR。
- License 许可
- MIT
- 最近更新
- 2026-11-06
- Stars
- ★ 5
- Forks
- 4
01 前言 Front Matter
- name
- github-deployment-change-audit
- author
- Hermes Agent
- license
- MIT
- version
- 1.0.0
- metadata
- { "hermes": { "tags": [ "GitHub", "Deployments", "Changelog", "Audit", "PRs" ], "related_skills": [ "github-code-review" ] } }
- description
- Audit a GitHub repo's recent deployments and summarize functional merged changes, excluding docs-only PRs.
02 资源文件 3
- 参考文档.cloud-manifest.json156 B
- 参考文档.gene-manifest.json266 B
- 参考文档phenotype.json2.3 KB
03 SKILL.md 正文
GitHub Deployment Change Audit
Use this when the user wants a concise summary of what functionally changed in a GitHub repository over a recent window (for example, last 24 hours), grounded in both deployment history and merged PRs.
When to use
- "What changed in deployments in the last day?"
- "What functional changes were merged recently?"
- Daily/recurring repo health or changelog briefs
- "Tell me what is live right now and what was reverted"
Core approach
1. Prefer GitHub API/gh over browser pages
The /deployments page may return a 404 or login wall when accessed unauthenticated in the browser. Prefer gh api for deployments and PR metadata.
Repository examples below use NousResearch/hermes-agent.
2. Get the current time and define the window
Always ground the time window with a live clock.
date -u '+%Y-%m-%dT%H:%M:%SZ'
date '+%Y-%m-%d %H:%M:%S %Z'
Use the first timestamp as now, then compute the cutoff (commonly 24h earlier).
3. Fetch recent deployments
gh api repos/OWNER/REPO/deployments?per_page=30
For each deployment in the time window, also fetch statuses:
gh api repos/OWNER/REPO/deployments/DEPLOYMENT_ID/statuses?per_page=5
Interpretation:
success= current active/latest successful deploymentinactive= older superseded deployment- lack of failures in statuses usually means there were no failed deployments in the window
Report:
- number of deployments in window
- latest/currently active deployment SHA and timestamp
- coarse status counts (
success,inactive, failures if present)
4. Fetch merged PRs in the same window
Use GraphQL for merged PR discovery:
gh api graphql -f query='query {
repository(owner:"OWNER", name:"REPO") {
pullRequests(first: 50, states: MERGED, orderBy: {field: UPDATED_AT, direction: DESC}) {
nodes {
number
title
mergedAt
url
author { login }
mergeCommit { oid }
}
}
}
}'
Filter locally to PRs with mergedAt >= cutoff.
Then fetch changed files per PR:
gh pr view PR_NUMBER --json files
Important: also check for direct commits on main in the same window so you don't miss non-PR changes or repo-maintenance noise that should be explicitly excluded. Example:
gh api repos/OWNER/REPO/commits?sha=main&since=CUTOFF&per_page=100
For each commit SHA, ask GitHub whether it belongs to a PR:
gh api repos/OWNER/REPO/commits/SHA/pulls -H 'Accept: application/vnd.github.groot-preview+json'
Use this to:
- catch functional direct commits not attached to a PR
- identify non-functional direct commits (for example
AUTHOR_MAP/ attribution-only churn) and exclude them cleanly - avoid accidentally reporting merge-queue helper commits as standalone functional changes
5. Exclude docs-only PRs
Treat a PR as docs-only if all changed files are documentation/content artifacts, for example:
website/- markdown-only files like
*.md - skill docs like
SKILL.md - repo docs such as
SECURITY.md - other purely static content if the user asked to exclude docs/content
Keep PRs that touch code, config, workflows, runtime logic, tests for behavioral changes, packaging, or platform adapters.
6. Detect net-effect reverts
Cross-reference deployment SHAs and merged PRs. If a feature PR is followed by a revert PR in the same window, call it out explicitly:
- feature merged
- revert merged shortly after
- therefore not part of the live net effect
Good signals:
- PR title starts with
Revert - same or overlapping touched files
- latest deployment SHA matches the revert commit rather than the original feature
7. Summarize by behavior, not by file list
Group kept PRs into categories like:
- major user-facing/platform changes
- messaging/gateway behavior
- provider/model/runtime fixes
- profile/env/plugin loading
- CLI/tooling/execution reliability
- security/redaction
- setup/packaging
For each bullet include:
- PR number
- short title
- one-line effect in plain English
8. Recommended output format
Use this structure:
### Deployment readout
- N deployments in the last 24 hours
- Current live deployment: SHA at TIME
- Status counts
### Important net effect
- Feature PR merged, then reverted
- Therefore not live
## Functional changes merged in the last 24 hours
### Biggest user-facing / platform changes
- #1234 — title — impact
### Messaging / gateway behavior
- ...
### Provider / runtime fixes
- ...
### Short take
- 3 to 6 bullets on the highest-signal net changes
Pitfalls
- Browser access to deployments may fail even when API access works; do not depend on the browser page.
- The deployments endpoint can return large payloads; keep page size bounded (
per_page=30is usually enough for a 24h window on active repos). ghoutput can be large; if needed, use a short Python helper to filter by timestamp locally.- Do not confuse
inactivedeployments with failed deployments. - Do not include docs-only PRs when the user asked for functional changes only.
Verification
Before finalizing:
- Confirm the time window with a live
datecall. - Confirm latest deployment SHA and timestamp from deployments API.
- Confirm merged PR list from GraphQL.
- Confirm file lists for borderline PRs before classifying them as docs-only or functional.
- Check for obvious revert pairs so the reported net effect matches what is live.
04 同仓库更多 Skills
网页抓取受阻恢复
blocked-page-recovery
当抓取失败时使用:403/429 状态码、付费墙(paywall)、WAF、机器人验证墙(bot wall)。
软件实施计划编写
writing-plans
在创建或更新可执行的软件计划时使用。除非用户明确要求将计划注册到 Doct,否则请将计划保留为本地文件。
测试驱动开发
test-driven-development
TDD:强制执行「红-绿-重构」(RED-GREEN-REFACTOR)循环,先写测试再写代码。
系统化根因调试
systematic-debugging
四阶段根因调试:先理解缺陷,再着手修复。
技术预研验证
spike
在正式构建前,通过一次性(可丢弃的)实验来验证某个想法。
代码变更并行清理精简
simplify-code
并行使用 3 个智能体(agent)对近期代码变更进行清理精简。