repo-cli

Installation
SKILL.md

repo-cli

Git repository summary CLI - one command, whole picture. Provides static summaries, interactive TUI, AI-powered commits, history/branch exploration, and surgical commit design.

Installation

cargo install repo-cli
# or build from source
git clone https://github.com/knrs/repo-cli && cd repo-cli && cargo install --path .

Commands

Summary (default)

repo                    # static summary with simple graph
repo -i                 # interactive TUI (panels: Branches/Commits/Status)
repo --graph            # full ASCII branch tree
repo --no-color         # plain output
repo -n 10              # show N recent commits
repo --fetch            # fetch remotes first
repo --stashes          # show detailed stash info
repo /path/to/repo      # target specific repo

AI Commit (commit, c, ic)

repo commit             # interactive: AI generates message, review in TUI
repo commit --ai claude # use specific provider (claude/codex/gemini)
repo commit --amend     # amend last commit
repo c                  # quick non-interactive commit
repo ic                 # interactive commit (alias)

Workflow: stage files (y=all, s=select, l=list, d=diff) -> AI generates message -> review (y=commit, e=edit, r=regenerate, d=diff).

Regeneration styles: c=concise, l=longer, s=shorter, d=detailed, or type custom instruction.

Explore (explore, e)

repo explore            # history + branch explorer TUI (default: History)
repo explore history    # explicit History tab
repo explore branches   # explicit Branches tab
repo e --page-size 100  # load 100 commits per page

Three tabs: Summary (1), History (2), Branches (3). Switch with Tab/Shift+Tab or number keys.

See references/explore-keybindings.md for full keybinding reference.

History Tab

  • Navigate commits with j/k, detail sub-tabs with h/l (Files/Diff/Blame)
  • / to filter: msg:text author:name date:YYYY-MM-DD path:src/ diff:pattern
  • x for actions: cherry-pick, create branch, revert, copy hash
  • a for AI: summarize, explain, find commits, range summary

Branches Tab

  • f cycle filter (local/remote/all), s cycle sort (name/date/activity)
  • c compare mode (select 2 branches)
  • x for actions: checkout, create, merge, rebase, delete, copy name
  • a for AI: summarize, compare, deletion advice, merge advice

Craft (craft)

repo craft              # surgical commit design TUI
repo craft --count 50   # show 50 commits
repo craft --last 5     # pre-select last 5

Actions per commit: reword, split, squash, fixup, drop, reorder, edit. Tab in reword mode triggers AI message generation.

See references/craft-keybindings.md for full keybinding reference.

Reword (reword)

repo reword             # interactive rebase to reword messages
repo reword --last 3    # auto-select last 3 commits
repo reword --all       # select all displayed commits
repo reword --count 30  # show 30 commits
repo reword --editor    # use $EDITOR instead of inline prompt

Sync (sync, s)

repo sync               # pull + push in one command
repo s --rebase         # use git pull --rebase

Aborts if uncommitted changes detected.

GitHub Operations

repo release 1.0.0      # create GitHub release (requires gh CLI)
repo release 1.0.0 --draft
repo stars               # list stargazers (first 100)
repo forks               # list forks with star counts

Self-Update

repo update              # check and install latest
repo update --check      # check only

AI Integration

Three providers auto-detected in order: Claude -> Codex -> Gemini.

Priority: --ai flag > default_ai in config > auto-detected.

Requires at least one CLI installed: claude, codex, or gemini.

AI features:

  • Commit: generate/regenerate messages from diff
  • Explore History: summarize, explain, find, range-summarize commits
  • Explore Branches: summarize, compare, deletion/merge advice
  • Craft Reword: Tab generates message from commit diff

Results cached per session. Diffs truncated to 8K chars with smart file distribution.

Configuration

Config file: ~/.config/repo/config.toml

default_ai = "claude"           # AI provider: claude/codex/gemini
auto_fetch = false              # fetch before summary
show_github_stats = true        # stars/forks in header
commit_style = "concise"        # AI commit style
message_box_style = "box"       # box/double_line/title_box/gutter
ai_provider = "claude"          # explore AI provider
ai_model = "claude-sonnet-4-6"  # explore AI model
stale_branch_days = 30          # days before branch is stale
ignore_files = ["*.local"]      # global never-stage patterns

.repoignore

Per-repo file at .repoignore - glob patterns for files to never stage:

scratch.*
*.local
debug/

Merged with global ignore_files. Hidden files shown as: N file(s) hidden by .repoignore.

Installs
1
First Seen
Apr 17, 2026