--- name: repo-scan description: Cross-stack source code asset audit — classifies every file, detects embedded third-party libraries, and delivers actionable four-level verdicts per module with interactive HTML reports. origin: https://github.com/haibindev/repo-scan tools: - file analysis - dependency detection - HTML report generation --- # repo-scan > Every ecosystem has its own dependency manager, but no tool looks across C++, Android, iOS, and Web to tell you: how much code is actually yours, what's third-party, and what's dead weight. ## When to Activate - Taking over a large legacy codebase and need a structural overview - Before major refactoring — identify what's core, what's duplicate, what's dead - Auditing third-party dependencies embedded directly in source (not declared in package managers) - Preparing architecture decision records for monorepo reorganization ## Installation ```bash # Copy into your Claude Code skills directory git clone https://github.com/haibindev/repo-scan.git cp -r repo-scan ~/.claude/skills/repo-scan ``` > Review the source before installing any agent skill. ## Core Capabilities | Capability | Description | |---|---| | **Cross-stack scanning** | C/C++, Java/Android, iOS (OC/Swift), Web (TS/JS/Vue) in one pass | | **File classification** | Every file tagged as project code, third-party, or build artifact | | **Library detection** | 50+ known libraries (FFmpeg, Boost, OpenSSL…) with version extraction | | **Four-level verdicts** | Core Asset / Extract & Merge / Rebuild / Deprecate | | **HTML reports** | Interactive dark-theme pages with drill-down navigation | | **Monorepo support** | Hierarchical scanning with summary + sub-project reports | ## Analysis Depth Levels | Level | Files Read | Use Case | |---|---|---| | `fast` | 1-2 per module | Quick inventory of huge directories | | `standard` | 2-5 per module | Default audit with full dependency + architecture checks | | `deep` | 5-10 per module | Adds thread safety, memory management, API consistency | | `full` | All files | Pre-merge comprehensive review | ## Workflow 1. **Scan**: `/repo-scan` runs a pre-scan pass to classify files and detect dependencies 2. **Analyze**: AI reviews the structured data and assigns verdicts per module 3. **Report**: Interactive HTML report generated with verdict distribution and drill-down ## Real-World Example On a 50,000-file C++ monorepo: - Found FFmpeg 2.x (2015 vintage) still in production - Discovered the same SDK wrapper duplicated 3 times - Identified 636 MB of committed Debug/ipch/obj build artifacts - Classified: 3 MB project code vs 596 MB third-party ## Best Practices - Start with `standard` depth for first-time audits - Use `fast` for monorepos with 100+ modules to get a quick inventory - Run `deep` incrementally on modules flagged for refactoring - Review the cross-module analysis for duplicate detection across sub-projects ## Links - [GitHub Repository](https://github.com/haibindev/repo-scan)