git-push

git-push is a skill for Claude Code, Codex from chengkj99/kj-skills. It costs 67 tokens per session (1,432 once invoked), scanned A, original, MIT.

A guided Git workflow that checks changes, creates a Conventional Commits-style message, stages files, commits them, and pushes the commit to a remote repository when explicitly asked.

In plain words
What is it for?
Use it to submit current code changes, create consistent commit messages, and send commits to the remote repository.
Why use it?
It removes the repetitive work of reviewing status, writing a commit message, and running the add, commit, and push commands. It also highlights risky files such as secrets before they are committed.

Skill for Claude CodeCodex

Written for Claude Code and Codex: shipped in a Claude Code plugin, but also agents/openai.yaml present.

Part of the kj-skills plugin — 34 skills, 1 command, 1 hook shipped together

Good fit Use it to submit current code changes, create consistent commit messages, and send commits to the remote repository.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/chengkj99/kj-skills/git-push
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.

Any agent
npx skills add chengkj99/kj-skills --skill git-push
Clone the repo
git clone --depth 1 https://github.com/chengkj99/kj-skills

Made for: Claude Code, Codex.

Or install kj-skills, the plugin that ships this one along with the rest of its 34 skills, 1 command, 1 hook.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for git-push

README.md
[![agentmods](https://agentmods.dev/badge/skills/chengkj99/kj-skills/git-push/github.svg)](https://agentmods.dev/skills/chengkj99/kj-skills/git-push)
Your own site
<a href="https://agentmods.dev/skills/chengkj99/kj-skills/git-push"><img src="https://agentmods.dev/badge/skills/chengkj99/kj-skills/git-push/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for git-push

Your own site · 80×15
<a href="https://agentmods.dev/skills/chengkj99/kj-skills/git-push"><img src="https://agentmods.dev/badge/skills/chengkj99/kj-skills/git-push.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,432 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.1 $0.00067 $0.01432
Opus 5 $0.00034 $0.00716
Sonnet 5 $0.00013 $0.00286
Haiku 4.5 $0.00007 $0.00143

Measured 9d ago against content hash ec6f6fbe7b64, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

git-push 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 9d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (examples/workflow.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

skills/git-push/SKILL.md · 142 lines

How it starts

The opening of the file, as written. The whole thing — 142 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Git Push(提交并推送)

自动化完整 git 工作流:检查状态 → 分析 diff → 生成提交说明 → git addgit commitgit push

适用场景

  • 用户明确要求提交、推送或「一条龙」完成 add/commit/push
  • 需要基于当前 diff 自动生成符合仓库风格的 commit message

若用户仅问「改了什么」「要不要提交」,不要执行本 skill,只回答或展示 git status / git diff

硬性约束(必须遵守)

  1. 仅在用户明确要求时git add / git commit / git push;未明确要求则停在分析或建议阶段。
  2. 禁止修改 git 配置(git config 等)。
  3. 禁止main / master 执行 push --force;若用户要求强推,先警告风险。
  4. 禁止默认使用 --no-verify / --no-gpg-sign,除非用户明确要求跳过 hook。
  5. 禁止提交明显含密钥的文件(.env*credentials**.pem 等);发现后警告并排除,除非用户确认仍要提交。
  6. 用户规则要求「不要 amend」时:仅在用户明确要求 amend、且 HEAD 为本会话创建且未推送时方可 --amend;hook 失败或 commit 被拒后新建 commit,不要 amend。
  7. 不要在用户未要求时 git push 到远程。

工作流

1. 检查状态

并行或依次执行:

git status
git diff --stat
git log --oneline -5

确认:是否有可提交改动、当前分支、与远程跟踪关系、近期 commit 风格。

2. 分析变更

git diff
git diff --cached

对新文件结合 git diff --stat 与 Read 理解意图。提交说明类型与示例见 references/commit-patterns.md

3. 生成提交说明

采用 Conventional Commits

<type>(<scope>): <简短描述>

[可选正文]

[可选 Co-Authored-By 行]

typefeat | fix | docs | style | refactor | test | chore

规则

  • 根据 diff 判断 type 与 scope(模块/目录名)
  • 标题约 50–72 字符,说明「做了什么、为何」,与 git log 近期风格一致
  • 正文可选;破坏性变更用 !BREAKING CHANGE: 注明
  • Co-Authored-By 仅在与用户约定或项目惯例需要时添加,勿硬编码错误模型名

4. 暂存与提交

只暂存与本次任务相关的文件;用户说「全部提交」时用:

git add -A

提交(HEREDOC 保证多行格式):

git commit -m "$(cat <<'EOF'
<type>(<scope>): <description>

EOF
)"
  • 若无改动可提交:告知用户,不要空提交
  • pre-commit hook 失败:修复问题后新建 commit,不要 amend(除非满足用户 amend 规则)

5. 推送到远程

git push

或指定上游:

git push -u origin "$(git branch --show-current)"

推送前检查

  • 若本地落后远程:提示先 git pull --rebase(或用户偏好的合并方式),不要自动 force push
  • 冲突或 push 被拒:说明原因,给出修复步骤,不擅自 force

错误处理

情况 处理
无改动 说明工作区干净,结束
commit 失败 读 hook/错误信息,修代码或格式后重新 commit
push 失败 检查权限、分支保护、是否需 pull/rebase
含敏感文件 列出路径,建议加入 .gitignore,默认不提交

Read the full file on GitHub · 142 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 9d ago First seen · 142 lines · 67 tokens per session scan A ec6f6fbe7b64

Subscribe to this mod's changes

git-push is a skill published in the GitHub repository chengkj99/kj-skills (14 stars, last pushed 7d ago), licensed MIT. It adds 67 tokens to every session and 1,432 once invoked, about $0.0003 per session on Opus 5. 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-30.