Claude-skill-registry gitinjest
Analyze GitHub repositories by converting to LLM-readable text. TRIGGER when user pastes github.com URL, asks "how does [library] work", or references external codebases. Supports public/private repos and subdirectories.
install
source · Clone the upstream repo
git clone https://github.com/majiayu000/claude-skill-registry
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/majiayu000/claude-skill-registry "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/data/gitinjest" ~/.claude/skills/majiayu000-claude-skill-registry-gitinjest && rm -rf "$T"
manifest:
skills/data/gitinjest/SKILL.mdsource content
Gitingest
TRIGGER CONDITIONS
USE when user message contains:
URLgithub.com/- "look at this repo" or "analyze this codebase"
- Questions about third-party library internals
SKIP when:
- URL is user's own project
- User just wants to clone/fork
Convert GitHub repos into text format using the CLI - output streams to stdout by default.
STREAMING ONLY (HARD DEFAULT)
ALWAYS stream to stdout with
-o -. DO NOT:
- Clone repos locally
- Write output files (
)-o file.txt - Redirect to disk (
)> out.txt - Create temp files
Only write to disk if user EXPLICITLY requests it.
# CORRECT - streams to stdout gitingest https://github.com/user/repo -o - gitingest https://github.com/user/repo -i "*.ts" -o - # WRONG - writes to disk (avoid unless user asks) gitingest https://github.com/user/repo -o output.txt gitingest https://github.com/user/repo > dump.txt
Gitingest CLI Commands for External Codebase Analysis
Key lesson: Always search broadly first (-i ".ts" for TypeScript, -i ".py" for Python, etc.) before narrowing down. The commands are powerful, but your search scope determines what you find.
Installation
pipx install gitingest
Linux Notes
- If
fails with PEP 668 error, usepip install --user
instead.pipx install gitingest - If
, ensuregitingest: command not found
is on PATH. Run~/.local/bin
then restart your shell.pipx ensurepath - Verify:
orgitingest --helppipx list | grep gitingest
Default Usage (Streaming to stdout)
# Stream output directly (no file created) gitingest https://github.com/username/repo -o - # Capture in variable for processing output=$(gitingest https://github.com/username/repo -o -)
Private Repositories
# Set token as environment variable export GITHUB_TOKEN=github_pat_... gitingest https://github.com/username/private-repo -o - # Or pass directly gitingest https://github.com/username/private-repo --token github_pat_... -o -
Subdirectories
# Analyze only specific part of repo gitingest https://github.com/user/repo/tree/main/src -o -
Basic Usage
- Get full repo overview (stdout)gitingest https://github.com/user/repo -o -
- Include submodulesgitingest https://github.com/user/repo --include-submodules -o -
File/Content Search
- Search files containing patterngitingest https://github.com/user/repo -i "pattern" -o -
- Find files by name/globgitingest https://github.com/user/repo -i "*filename*" -o -
- Get specific file contentgitingest https://github.com/user/repo -i "path/to/file" -o -
Filtering
- Exclude files matching patterngitingest https://github.com/user/repo -e "pattern" -o -
- Include TS files, exclude node_modulesgitingest https://github.com/user/repo -i "*.ts" -e "node_modules/*" -o -
Key Options
or-o -
: Stream to stdout (no temp file)--output -
or--token
: GitHub token for private repos-t
: Include git submodules--include-submodules
: Include files normally ignored by .gitignore--include-gitignored
Output Structure
The CLI returns formatted text with:
- Summary: File count, size, token count
- Tree: Directory visualization
- Content: All code combined and formatted