← 返回
未分类 中文

Git Helper

Git workflow automation for commits, pushes, rebases, status checks, and branch operations. Use when working with git repositories for: (1) Checking status,...
Git工作流自动化,支持提交、推送、变基、状态检查和分支操作。适用于Git仓库管理:(1) 检查状态...
dougchambes dougchambes 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 505
下载
💾 1
安装
1
版本
#latest

概述

Git Helper

Handles all git operations through safe, consistent workflows.

Core Workflows

Status Check

Before any git operation, run git status to understand repository state.

Staging

  • git add - Stage specific files
  • git add -A - Stage all changes
  • git add -p - Interactive staging (review hunks)

Committing

Use Conventional Commits format:

<type>(<scope>): <description>

[optional body]

[optional footer]

Types: feat, fix, docs, style, refactor, test, chore

Scope: Optional, usually the component or area affected

Description: Imperative present tense ("add feature" not "added feature")

Push/Pull

  • git push - Push to remote (default: current branch)
  • git pull --rebase - Fetch and rebase (preferred default)
  • git pull - Fetch and merge (when merge history needed)

Rebasing

  • git rebase -i HEAD~N - Interactive rebase last N commits
  • Always confirm branch state before rebasing
  • Never rebase shared/public branches without explicit permission

Log/Diff

  • git log --oneline -N - View last N commits
  • git diff - Unstaged changes
  • git diff --staged - Staged changes
  • git diff HEAD~N - Changes over last N commits

Safety Rules

  1. Never force push without explicit user permission
  2. Always check status before any operation
  3. Confirm destructive actions (rebase, reset, hard, force push)
  4. Stay within workspace boundaries - respect user's file access rules
  5. Pull before push when working with shared branches

When to Read references/workflows.md

Load this reference file when:

  • User needs detailed Conventional Commits specification
  • Complex rebase/merge scenarios require guidance
  • Branch strategy consultation needed
  • Conflict resolution guidance required

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-30 23:28 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

dev-programming

Mcporter

steipete
使用 mcporter CLI 直接列出、配置、认证及调用 MCP 服务器/工具(支持 HTTP 或 stdio),涵盖临时服务器、配置编辑及 CLI/类型生成功能。
★ 195 📥 67,418
it-ops-security

File Organizer

dougchambes
工作区文件组织与批量操作管理。用于整理文件:(1) 将文件移动到正确目录;(2) 批量重命名
★ 0 📥 692
dev-programming

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 677 📥 325,835