Wrap the live coordinator in project Cursor capabilities so agents default to leases, docs apply, and daemon enqueue. Track skills/hooks/mcp via .gitignore exceptions; guard destructive git with ask permission.
24 lines
1.3 KiB
Plaintext
24 lines
1.3 KiB
Plaintext
---
|
||
description: Agent-System 写操作必须经 agentctl(租约、docs apply、候选合入);禁止绕过治理直接改共享文档或 push。
|
||
alwaysApply: true
|
||
---
|
||
|
||
# agentctl 强制治理
|
||
|
||
本仓库由 agentctl 管理面协调(SQLite + launchd daemon)。细则见 [AGENTS.md](../../AGENTS.md) 与 [操作规范](../../.doc/ops/2026-09-21-agent-worktree-workflow.md);流程技能见 `.cursor/skills/agentctl-*`。
|
||
|
||
## 硬边界
|
||
|
||
1. **写仓库**:必须 `agentctl with` / MCP `lease_run`。裸 `git commit` 会被 agentctl pre-commit hook 拒绝。
|
||
2. **共享文档**:`.doc/ops/CURRENT.md`、`.doc/status/FEATURE-MATRIX.md` 只能 `docs apply`(行级 CAS;MATRIX 键为 `record_id`)。
|
||
3. **合入 local dev**:`validate` 后 `queue enqueue`(daemon `--ff-only`)或受控 `integrate`;禁止直接改主目录 `dev` tip。
|
||
4. **禁止默认**:未授权 `git push`、晋升 test/main、`--force` 清理、卸载 launchd coordinator、改 gap-matrix / 升 MATRIX 状态值冒充发布。
|
||
|
||
## 会话路径
|
||
|
||
- 启动 → skill `agentctl-session-start`
|
||
- 建场 → `agentctl-worktree-setup`
|
||
- 写回 → `agentctl-lease-write`
|
||
- 合入/收口 → `agentctl-integrate-closeout`
|
||
- MCP 工具定义见 `.cursor/mcp.json` → `scripts/mcp/agentctl-mcp.mjs`
|