Token导航 LogoToken导航TokenDH.com
待分类需要联网github未标认证来源可访问许可证需确认审计通过

gitGit 版本控制

Agent Skill

git 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

539

周安装

22

GitHub Stars

1

下载量

172
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:git(Git 版本控制)
来源仓库:https://github.com/laststance/skills
仓库路径:skills/git
安装命令:
npx skills add https://github.com/laststance/skills --skill git
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/laststance/skills --skill git

简介

git 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中围绕仓库状态进行整理。

  • 适用于版本控制、代码审查等开发协作场景。
  • 通过指定仓库或 Issue 编号获取相关信息并生成报告。
  • 安装前需确认权限范围和维护状态,注意可能涉及文件读写和命令执行。
  • git 属于待分类类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

Git — Intelligent Git Operations

Smart git workflow with automatic Conventional Commit message generation.

<essential_principles>

Safety Rules

  • Conventional Commits: All commit messages MUST follow type(scope): description format

- Types: feat, fix, refactor, docs, test, chore, perf, ci, build, style - Scope: optional, derived from changed files/directories - Description: imperative mood, lowercase, no period

  • Destructive operations require user confirmation: push --force, reset --hard, branch -D, rebase on shared branches, clean -f
  • Never skip hooks: Do not use --no-verify unless user explicitly requests it
  • Smart Commit always active: Analyze staged changes to generate meaningful messages automatically

</essential_principles>

Operations

status

Analyze repository state and provide actionable summary.

  1. Run git status (never use -uall flag)
  2. Run git diff --stat for change overview
  3. Present:

- Staged / unstaged / untracked file counts - Branch info and upstream tracking status - Recommended next action (e.g., "Ready to commit", "Changes need staging")

commit

Generate a Conventional Commit from change analysis.

  1. Run git status and git diff --cached (staged) and git diff (unstaged)
  2. Run git log --oneline -5 to match existing commit style
  3. Analyze changes:

- Determine type from nature of changes (new feature → feat, bug fix → fix, etc.) - Determine scope from affected directories/files - Write concise description focusing on "why" not "what"

  1. If nothing is staged, ask user what to stage
  2. Stage files with specific file names (avoid git add -A or git add.)
  3. Commit using HEREDOC format: git commit -m "$(cat <<'EOF' type(scope): description EOF)"

push

Sync local commits with remote.

  1. Check upstream tracking: git rev-parse --abbrev-ref --symbolic-full-name @{u}
  2. If no upstream, push with -u: git push -u origin <branch>
  3. If upstream exists: git push
  4. Never force-push without user confirmation

pull

Fetch and integrate remote changes.

  1. git pull --rebase (prefer rebase over merge for clean history)
  2. If conflicts arise, guide user through resolution

branch

Create, switch, or manage branches.

  1. Create: git checkout -b <name> with naming convention type/description (e.g., feat/add-login, fix/header-alignment)
  2. Switch: git checkout <name>
  3. List: git branch -a with upstream status
  4. Delete: git branch -d <name> (use -D only with user confirmation)

merge

Guided merge with conflict resolution support.

  1. Check target branch is up to date: git fetch origin
  2. Execute merge: git merge <source>
  3. If conflicts:

- List conflicting files - Show conflict markers for each file - Guide user through resolution options - After resolution: git add <resolved-files> && git commit

stash

Temporarily save uncommitted changes.

  1. Save: git stash push -m "description"
  2. List: git stash list
  3. Apply: git stash pop (or apply to keep in stash)

log

View commit history with useful formatting.

  1. Default: git log --oneline -20
  2. Detailed: git log --oneline --graph --all -20

Examples

/git status
/git commit
/git push
/git branch feat/dark-mode
/git merge main
/git stash save work in progress
/git log

Boundaries

Will:

  • Execute git operations with intelligent automation
  • Generate Conventional Commit messages from change analysis
  • Provide workflow guidance and best practice recommendations
  • Handle conflict resolution with step-by-step guidance

Will Not:

  • Modify repository configuration without explicit authorization
  • Execute destructive operations without user confirmation
  • Include project-specific workflow rules (those belong in CLAUDE.md or AGENTS.md)

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

36.26%
按下载量换算62

Claude

30.22%
按下载量换算52

Cursor

19.68%
按下载量换算34

Gemini CLI

9.05%
按下载量换算16

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills