gitnudge recover shows the exact undo command.<<<<<<< / ======= / >>>>>>> markers.gitnudge status shows commit X/Y and the subject of the commit currently being applied.gitnudge explain asks Claude to describe a conflict in plain English — no resolution, just understanding.rebase --auto records every AI fix (file, confidence, change summary) so you can review what Claude actually changed.gitnudge analyze detects fast-forward, already-up-to-date, and unrelated-history cases — and surfaces conflict risk before you rebase.# Install directly from GitHub
pip install git+https://github.com/GitNudge/gitnudge.git
# Install a specific version
pip install git+https://github.com/GitNudge/gitnudge.git@v0.3.0
git clone https://github.com/GitNudge/gitnudge.git
cd gitnudge
pip install -e .
export ANTHROPIC_API_KEY="your-api-key"
# Or use the config command
gitnudge config --set-key
# Analyze potential conflicts first
gitnudge analyze main
# Rebase with AI assistance (writes a recovery snapshot)
gitnudge rebase main
# Get AI help when conflicts occur
gitnudge resolve
# Or just get a plain-language explanation
gitnudge explain
# Continue, skip, or abort like normal git
gitnudge continue
gitnudge skip
gitnudge abort
# Lost? Show how to undo the rebase
gitnudge recover
gitnudge rebase <target>
Pre-flight check, snapshot HEAD, then rebase onto target
gitnudge analyze <target>
Analyze conflicts; detects fast-forward / up-to-date / unrelated history
gitnudge resolve [file]
AI-assisted conflict resolution (one file, all files, or auto)
gitnudge explain [file]
Plain-language explanation of a conflict without proposing a fix
gitnudge continue
Continue rebase; reports applied/remaining commit counts
gitnudge skip
Skip the current commit (git rebase --skip)
gitnudge abort
Abort and clear the recovery snapshot
gitnudge recover
Print the saved pre-rebase SHA and the exact git reset --hard command
gitnudge status
Branch, rebase state, live progress, conflicted files, safety SHA
gitnudge config
Show, set API key, set model, or reset configuration
gitnudge rebase main --dry-run # Preview without changes
gitnudge rebase main --auto # Auto-apply high/medium-confidence AI fixes
gitnudge rebase main --force # Skip pre-flight checks (NOT recommended)
gitnudge rebase -i HEAD~5 # Interactive rebase
gitnudge resolve --all # Walk through every conflicted file
gitnudge resolve --auto # Auto-apply suggestions without confirmation
gitnudge continue --ai-verify # Refuse to continue if any staged file still has markers
gitnudge analyze --detailed main # Detailed AI risk analysis
gitnudge -v rebase main # Global --verbose / -v (or --quiet / -q)
GitNudge can be configured via environment variables or a config file at ~/.config/gitnudge/config.toml (saved with 0o600 permissions). All values are validated with pydantic.
| Variable | Description |
|---|---|
ANTHROPIC_API_KEY |
Your Anthropic API key (required) |
GITNUDGE_MODEL |
Claude model to use (default: claude-sonnet-4-20250514) |
GITNUDGE_CONFIG |
Path to config file (default: ~/.config/gitnudge/config.toml) |
GITNUDGE_NO_COLOR |
Disable colored output |
NO_COLOR |
Standard no-color flag (also disables colored output) |
GITNUDGE_LOG_LEVEL |
Log level: DEBUG, INFO, WARNING, ERROR (default: WARNING) |
# ~/.config/gitnudge/config.toml
[api]
model = "claude-sonnet-4-20250514"
max_tokens = 4096
[behavior]
auto_stage = true
show_previews = true
max_context_lines = 500
auto_resolve = false
[ui]
color = true
verbosity = "normal"
Questions? Reach out at info@gitnudge.ai