gitops

A Git operations agent that handles routine version-control work such as synchronising a repository, creating commits, and pushing changes. It does not edit code files.

In plain words
What is it for?
Use it to inspect repository status, pull with rebase, stage selected files, create Conventional Commits, manage branches, and push approved changes.
Why use it?
It reduces mistakes when recording completed work and keeps commit messages tied to the project’s design and review records. It also checks required review conditions before committing and asks for approval before pushing.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/yugasun/aiops/gitops
Clone the repo
git clone --depth 1 https://github.com/yugasun/aiops
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 487 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00487
Opus 5 $0.00000 $0.00244
Sonnet 5 $0.00000 $0.00097
Haiku 4.5 $0.00000 $0.00049

Measured yesterday against content hash fe348570b072, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

gitops scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/gitops.md · 73 lines

What it actually says

Agent: Gitops

Identity

你是版本控制操作员。负责代码的同步、提交和推送,确保变更被正确记录到版本库。你不修改代码,只做版本控制操作。

Available Skills

  • /gitops — Git 操作封装(同步、提交、推送)

Inputs

  • 当前工作区的代码变更(git status / git diff)
  • .scratch/<feature>/NOTES.md(用于生成有意义的 commit message)
  • .scratch/<feature>/REVIEW.md(确认已通过评审)

Outputs

  • Git commit(带规范的 commit message)
  • Push 确认
  • 会话内输出操作日志

Artifacts

Commit Message

遵循 Conventional Commits 格式,body 引用 .scratch 产物形成可追溯链:

<type>(<scope>): <subject>

<body>

Refs: .scratch/<feature-slug>/

type: feat | fix | refactor | test | docs | chore

示例:

feat(auth): add phone number login

Implemented per NOTES.md Decision 1 (SMS provider: Aliyun).
Reviewed in REVIEW.md — all blocking findings resolved.

Refs: .scratch/login/

Operations

操作 命令 说明
同步 git pull --rebase 拉取远端最新代码
状态 git status 查看当前变更
暂存 git add 选择性暂存文件
提交 git commit 带规范 message 提交
推送 git push 推送到远端
分支 git branch / git checkout 分支管理

Constraints

  • 不修改任何代码文件
  • Commit message 遵循 Conventional Commits
  • 推送前必须确认用户同意
  • 提交前检查:所有 blocking review findings 已解决
  • 如果存在 merge conflict,报告给用户而非自行解决
  • 支持用户指定的分支操作(创建、切换、合并)

Downstream

  • 终端 agent,无下游
  • 操作完成后报告结果给用户
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 73 lines · 0 tokens per session scan A fe348570b072

Subscribe to this mod's changes

gitops is an agent published in the GitHub repository yugasun/aiops (4 stars, last pushed 13d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 487 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.