Agent SkillsTencent/libpag › commit

commit

GitHub

仅执行本地Git提交,不推送。根据暂存状态自动处理文件添加,生成符合规范的提交信息并输出结果。

.codebuddy/skills/commit/SKILL.md Tencent/libpag

Trigger Scenarios

需要保存本地代码更改但不希望推送到远程仓库时 用户明确要求只进行本地commit操作时

Install

npx skills add Tencent/libpag --skill commit -g -y
More Options

Non-standard path

npx skills add https://github.com/Tencent/libpag/tree/main/.codebuddy/skills/commit -g -y

Use without installing

npx skills use Tencent/libpag@commit

指定 Agent (Claude Code)

npx skills add Tencent/libpag --skill commit -a claude-code -g -y

安装 repo 全部 skill

npx skills add Tencent/libpag --all -g -y

预览 repo 内 skill

npx skills add Tencent/libpag --list

SKILL.md

Frontmatter
{
    "name": "commit",
    "description": "Commit local changes without pushing.",
    "disable-model-invocation": true
}

Commit — Local Commit Only

Commits local changes to the current branch. Does not push or create a PR.

Instructions

  • NEVER push. This skill only creates local commits.
  • All user-facing text must use the language the user has been using in the conversation. Do not default to English.

Stage & Commit

Run git status --porcelain and inspect the output:

  • No output → no local changes. Inform the user and stop.
  • Staged changes exist, no unstaged changes → proceed directly to commit.
  • Staged changes exist, unstaged changes also exist → ask the user: commit only the staged files (partial), or stage everything (full)? If partial: skip staging (files are already staged). If full: run git add -A first.
  • No staged changes, unstaged changes exist → run git add -A to stage everything, then commit.

Read the staged diff (git diff --cached) and generate a commit message following the project's commit conventions. If no convention is found, default to a concise English message under 120 characters ending with a period, with no other punctuation, focusing on user-perceivable changes.

Commit, then output a single line in the format: 已提交 {short_hash}:{commit message}

If the user chose partial, also inform them that unstaged changes remain and were not included in this commit.

Version History

  • dc85cfd Current 2026-08-20 19:02

Same Skill Collection

.codebuddy/skills/accept-baseline/SKILL.md
.codebuddy/skills/cr/SKILL.md
.codebuddy/skills/pagx/SKILL.md
.codebuddy/skills/pr/SKILL.md
.codebuddy/skills/squash/SKILL.md

Metadata

Files
0
Version
dc85cfd
Hash
ffb06862
Indexed
2026-08-20 19:02

Accueil - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-28 21:46
浙ICP备14020137号-1 $Carte des visiteurs$