repo_monitor
Monitors repository changes by checking new commits and managing watermarks. Supports status, check, and reset actions for test impact analysis.
Instructions
统一仓库监控工具。仓库列表在 monitors.conf.json 中配置(直接编辑即可,无需 MCP 工具)。
三种操作(通过 action 参数选择):
status — 查看仓库水位、快照、上次检查时间
check — 检查新提交(首次自动初始化水位),驱动水位更新 + seenShas 去重
reset — 重置水位到指定 MR/日期。sinceDate 模式自动定位迭代第一个 MR 的 base commit
范围定位(二选一,不传则遍历全部):
name — 仓库别名
module — 模块名(批量操作该模块下所有仓库)
配合 CronCreate 定时监控: /cron "*/15 * * * *" "repo_monitor(action='check')"
敏捷迭代重置: repo_monitor(action="reset", module="订单系统", label="Sprint 25 kickoff", sinceDate="2026-06-13")
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| action | Yes | 操作类型:status(查看状态)/ check(检查新提交)/ reset(重置水位) | |
| name | No | 仓库别名(与 module 二选一,不传则遍历全部) | |
| module | No | 模块名(与 name 二选一,不传则遍历全部) | |
| label | No | 重置标签(如 'Sprint 25 kickoff'),用于快照回顾 | |
| sinceDate | No | 迭代开始日期(ISO 8601),如 '2026-06-13'。 |