git

A guide to using Git, the version-control system that records code changes and supports branches and collaboration. It covers repository status, diffs, history, staging, commits, branches, remotes, merges, rebases, tags, worktrees, and conflict resolution.

In plain words
What is it for?
Use it to check status, inspect diffs and history, stage and commit files, manage branches and remotes, merge or rebase, stash work, tag releases, cherry-pick changes, bisect regressions, and resolve conflicts.
Why use it?
It provides the commands needed to inspect and manage code history without having to remember Git syntax. It also helps compare changes and investigate when a regression was introduced.

Skill for Claude CodeCodex

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 skills/bug-ops/zeph/git
Any agent
npx skills add bug-ops/zeph --skill git
Clone the repo
git clone --depth 1 https://github.com/bug-ops/zeph

Made for: Claude Code, Codex.

Per session 106 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,295 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.00106 $0.02295
Opus 5 $0.00053 $0.01148
Sonnet 5 $0.00021 $0.00459
Haiku 4.5 $0.00011 $0.00230

Measured 2d ago against content hash 18697a16f0ea, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

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

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.

.zeph/skills/git/SKILL.md · 464 lines

How it starts

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

Git Operations

Status and Information

git status            # working tree status
git status -s         # short format
git branch -vv        # branches with tracking info

Viewing Changes

# Unstaged / staged / between branches
git diff
git diff --cached
git diff main..feature

# Changes since common ancestor (useful for PRs)
git diff main...feature

# Diff specific file
git diff -- PATH

# Word-level diff
git diff --word-diff

# Stat summary
git diff --stat

# Show a specific commit
git show COMMIT

# Show file at specific commit
git show COMMIT:PATH

Commit History

# Recent commits (compact)
git log --oneline -20

# With diffs
git log -p -5

# Graph view
git log --oneline --graph --all

# With file stats
git log --stat

# Filter by author / date / message / file
git log --author="NAME"
git log --since="2025-01-01" --until="2025-06-01"
git log --grep="fix"
git log -- PATH

# Commits that added/removed a string (pickaxe)
git log -S "function_name"

# Custom format
git log --pretty=format:"%h %ad %s (%an)" --date=short

# Who changed each line
git blame FILE
git blame -L 10,20 FILE

Staging

# Stage specific files
git add FILE1 FILE2

# Stage all tracked file changes
git add -u

# Stage everything (tracked + untracked)
git add -A

# Stage hunks interactively
git add -p

# Unstage file (keep changes)
git reset HEAD FILE

# Discard unstaged changes
git restore FILE

# Restore file from specific commit
git restore --source=COMMIT FILE

Committing

# Commit with message
git commit -m "message"

# Multi-line message
git commit -m "subject" -m "body"

# Stage tracked files and commit
git commit -a -m "message"

# Amend last commit
git commit --amend

# Amend without changing message
git commit --amend --no-edit

# Empty commit (trigger CI)
git commit --allow-empty -m "trigger build"

Undoing Commits

# Revert a commit (creates new inverse commit)
git revert COMMIT

# Revert without auto-commit
git revert --no-commit COMMIT

# Revert a merge commit (keep first parent)
git revert -m 1 MERGE_COMMIT

# Reset to commit (keep changes staged)
git reset --soft COMMIT

# Reset to commit (keep changes unstaged)
git reset --mixed COMMIT

# Reset to commit (discard all changes)
git reset --hard COMMIT

Read the full file on GitHub · 464 lines

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. 2d ago First seen · 464 lines · 106 tokens per session scan A 18697a16f0ea

Subscribe to this mod's changes

git is a skill published in the GitHub repository bug-ops/zeph (57 stars, last pushed 7d ago), licensed MIT. It adds 106 tokens to every session and 2,295 once invoked, about $0.0005 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.