github-linguist/linguist
Programming language detection library used on GitHub.com
- Chart
- Not on a chart right now
- Stars
- 13.8k
What it is
Linguist is a Ruby library used on GitHub.com to detect blob languages, ignore binary or vendored files, suppress generated files in diffs, and generate language breakdown graphs. It can be used in Ruby applications or via the `github-linguist` command-line executable.
Who it is for
Developers who want to analyze repository language statistics or inspect and override how GitHub detects file languages would use it.
Why it is trending
Created in 2011, it has 13,796 total stars, gained 24 stars today, and remains actively maintained with its v9.7.0 release in August 2026. It stands out as the actual library powering language detection on GitHub.com.
Main features
- Analyzes full Git repositories, specific revisions (`--rev`), or single files
- Ignores binary and vendored files and suppresses generated files in diffs
- Outputs file breakdowns (`--breakdown`), detection strategies (`--strategies`), and JSON (`--json`)
- Supports `.gitattributes` overrides and pre-built Docker images
Summarized on November 17, 2026 from the README and repository data. It can be wrong; check the source before relying on it. Report a wrong summary