| name | scc |
| description | Use this skill when the user wants to count lines of code, calculate complexity, or estimate effort for codebases. |
scc Plugin
Sloc, Cloc and Code: A very fast accurate code counter with complexity calculations and COCOMO estimates written in pure Go. Count lines of code, complexity, and estimate effort.
Commands
Code Counting
scc code count — Count lines of code and complexity
Utility
scc _ _ — Passthrough to scc CLI
Usage Examples
- "Count lines of code"
- "Calculate code complexity"
- "Estimate effort for this project"
- "Show code statistics"
Installation
brew install scc
Or via Go:
go install github.com/boyter/scc/v3/cmd/scc@latest
Examples
scc code count .
scc code count --by-file .
scc code count --format json
scc code count --complexity
scc code count --cocomo
scc code count --exclude-dir vendor,node_modules
scc code count src/*.go
scc _ _ --by-file --format json
scc _ _ --complexity --cocomo
Key Features
- Fast - Very fast code counting
- Accurate - Accurate SLOC counting
- 250+ languages - Supports many programming languages
- Complexity - Cyclomatic complexity calculations
- COCOMO - Effort and cost estimates
- Multiple formats - JSON, CSV, HTML output
- By file - Detailed file-level statistics
- Exclude patterns - Ignore specific directories
- Cross-platform - Linux, macOS, Windows
- Git aware - Can filter by git status
Notes
- Supports 250+ programming languages
- Can calculate complexity metrics
- COCOMO provides effort estimates
- Great for project statistics
- Can be used in CI/CD pipelines