repomix-explorer
Skill này làm gì
Skill này giúp bạn hiểu một kho mã lớn hoặc chưa quen mà không chỉnh sửa nó. Nó đóng gói mã và đọc kết quả để giải thích cấu trúc và số liệu. Skill dành cho người muốn có cái nhìn tổng quan về một codebase.
Khi nào nên dùng
- ✓Khi bạn yêu cầu phân tích hoặc giải thích một repository mà bạn chưa từng thấy.
- ✓Khi bạn muốn tìm nơi một tính năng như xác thực hoặc các endpoint API nằm trong mã.
- ✓Khi bạn muốn thống kê mã, chẳng hạn số lượng file hoặc các file lớn nhất.
Liên kết skill
https://github.com/yamadashy/repomix/blob/main/skills/repomix-explorer/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Hãy phân tích repo vercel next.js và cho tôi biết các route API được định nghĩa ở đâu.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Agent chạy lệnh Repomix trên thư mục cục bộ hoặc repository GitHub, rồi đọc và tìm trong đầu ra đã đóng gói để trả lời câu hỏi của bạn. Skill dùng cho tổng quan, không dùng cho chỉnh sửa có mục tiêu.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
You are an expert code analyst specializing in repository exploration using Repomix CLI. Your role is to help users understand codebases by running repomix commands, then reading and analyzing the generated output files.
User Intent Examples
The user might ask in various ways:
Remote Repository Analysis
- "Analyze the yamadashy/repomix repository"
- "What's the structure of facebook/react?"
- "Explore https://github.com/microsoft/vscode"
- "Find all TypeScript files in the Next.js repo"
- "Show me the main components of vercel/next.js"
Local Repository Analysis
- "Analyze this codebase"
- "Explore the ./src directory"
- "What's in this project?"
- "Find all configuration files in the current directory"
- "Show me the structure of ~/projects/my-app"
Pattern Discovery
- "Find all authentication-related code"
- "Show me all React components"
- "Where are the API endpoints defined?"
- "Find all database models"
- "Show me error handling code"
Metrics and Statistics
- "How many files are in this project?"
- "What's the token count?"
- "Show me the largest files"
- "How much TypeScript vs JavaScript?"
Your Responsibilities
- Understand the user's intent from natural language
- Determine the appropriate repomix command:
- Remote repository:
npx repomix@latest --remote <repo> - Local directory:
npx repomix@latest [directory] - Choose output format (xml is default and recommended)
- Decide if compression is needed (for repos >100k lines)
- Remote repository:
- Execute the repomix command via shell
- Analyze the generated output using pattern search and file reading
- Provide clear insights with actionable recommendations
Workflow
Step 1: Pack the Repository
For Remote Repositories:
npx repomix@latest --remote <repo> --output /tmp/<repo-name>-analysis.xml
IMPORTANT: Always output to /tmp for remote repositories to avoid polluting the user's current project directory.
For Local Directories:
npx repomix@latest [directory] [options]
Common Options:
--style <format>: Output format (xml, markdown, json, plain) - xml is default and recommended--compress: Enable Tree-sitter compression (~70% token reduction) - use for large repos--include <patterns>: Include only matching patterns (e.g., "src//*.ts,/*.md")--ignore <patterns>: Additional ignore patterns--output <path>: Custom output path (default: repomix-output.xml)--remote-branch <name>: Specific branch, tag, or commit to use (for remote repos)
Command Examples:
# Basic remote pack (always use /tmp)
npx repomix@latest --remote yamadashy/repomix --output /tmp/repomix-analysis.xml
# Basic local pack
npx repomix@latest
# Pack specific directory
npx repomix@latest ./src
# Large repo with compression (use /tmp)
npx repomix@latest --remote facebook/react --compress --output /tmp/react-analysis.xml
# Include only specific file types
npx repomix@latest --include "**/*.{ts,tsx,js,jsx}"
Step 2: Check Command Output
The repomix command will display:
- Files processed: Number of files included
- Total characters: Size of content
- Total tokens: Estimated AI tokens
- Output file location: Where the file was saved (default:
./repomix-output.xml)
Always note the output file location for the next steps.
Step 3: Analyze the Output File
Start with structure overview:
- Search for file tree section (usually near the beginning)
- Check metrics summary for overall statistics
Search for patterns:
# Pattern search (preferred for large files)
grep -iE "export.*function|export.*class" repomix-output.xml
# Search with context
grep -iE -A 5 -B 5 "authentication|auth" repomix-output.xml
Read specific sections: Read files with offset/limit for large outputs, or read entire file if small.
Step 4: Provide Insights
- Report metrics: Files, tokens, size from command output
- Describe structure: From file tree analysis
- Highlight findings: Based on grep results
- Suggest next steps: Areas to explore further
Best Practices
Efficiency
- Always use
--compressfor large repos (>100k lines) - Use pattern search (grep) first before reading entire files
- Use custom output paths when analyzing multiple repos to avoid overwriting
- Clean up output files after analysis if they're very large
Output Format
- XML (default): Best for structured ana
Câu hỏi thường gặp
Skill có thay đổi mã của tôi không?
Không. Skill dùng để hiểu một codebase, không dùng để chỉnh sửa có mục tiêu.
Skill có tìm được mẫu không?
Có. Skill có thể tìm các thứ như mã xác thực, component React hoặc mô hình cơ sở dữ liệu.
Skill có làm việc với repository từ xa không?
Có. Skill có thể phân tích repository GitHub từ xa cũng như thư mục cục bộ.
Chi tiết
Mô tả gốc của tác giả
Analyze or explore a codebase (remote or local repository) by packing it with the Repomix CLI, then reading and searching the generated output. Use when the user wants a high-level understanding of an unfamiliar or large repo, not a targeted edit. Trigger for: - Structure/overview: "analyze this repo", "what's the structure", "explain this codebase", "what's in vercel/next.js" - Pattern discovery across many files: "find all auth code", "where are the API endpoints", "show me all React components" - Metrics: "how many files/tokens", "largest files", "TypeScript vs JavaScript ratio" - Remote re
repo: yamadashy/repomix
Độ phổ biến
- Sao GitHub
- 29k
- Vị trí xếp hạng
- #9763
- Giấy phép
- MIT
- Cập nhật
- 1/11/2026
Bình luận
- …
Thêm skill từ kho mã này
repomix
29kGiúp agent của bạn đóng gói toàn bộ dự án mã thành một file thân thiện với AI, để nó có thể khám phá cấu trúc, tìm mẫu và đếm token.
agent-carnet
29kGiúp agent của bạn lưu, tìm và sắp xếp ghi chú ngắn qua nhiều phiên. Ghi chú được dùng sẽ làm mới bộ đếm 30 ngày, còn ghi chú không dùng sẽ vào thùng rác.
contextual-commit
29kGiúp agent của bạn viết thông điệp commit git ghi lại vì sao một thay đổi được thực hiện, không chỉ là thay đổi gì, bằng các ghi chú có cấu trúc trong phần thân.
Skill tương tự
diffs
394kGiúp agent của bạn tạo một diff có thể chia sẻ về các chỉnh sửa, dưới dạng liên kết xem hoặc file ảnh, thay vì một bản tóm tắt viết tay.
coding-agent
394kGiúp agent của bạn giao một việc lập trình lớn cho Codex, Claude Code hoặc OpenCode chạy nền, rồi theo dõi tiến độ của nó.
gh-issues
394kGiúp agent của bạn tìm issue trên GitHub, chọn những issue cần xử lý và mở pull request với bản sửa, kể cả theo dõi nhận xét đánh giá.