This library is used on GitHub.com to detect blob languages, ignore binary or vendored files, suppress generated files in diffs, and generate language breakdown graphs. Linguist is a Ruby library so you will need a recent version of Ruby installed. There are known problems with the macOS/XCode supplied version of Ruby that causes problems installing some of the dependencies. Accordingly, we highly recommend you install a version of Ruby using Homebrew, rbenv, rvm, ruby-build, asdf or other packaging system, before attempting to install Linguist and the dependencies. Linguist uses charlock_holmes for character encoding and rugged for libgit2 bindings for Ruby. These components have their own dependencies. A repository's languages stats can also be assessed from the command line using the github-linguist executable. Without any options, github-linguist will output the breakdown that correlates to what is shown in the language stats bar.

Features

  • Create a language stats bar which displays the languages percentages for the files in the repository
  • Detect blob languages, ignore binary or vendored files
  • Suppress generated files in diffs, and generate language breakdown graphs
  • Linguist takes the list of languages it knows from languages.yml and uses a number of methods to try and determine the language used by each file
  • Linguist goes through all the files in a repository and excludes all files that it determines to be binary data
  • The results of this analysis are cached for the lifetime of your repository

Project Samples

Project Activity

See All Activity >

Categories

Graphics, Libraries

License

MIT License

Follow Linguist

Linguist Web Site

You Might Also Like
Our Free Plans just got better! | Auth0 by Okta Icon
Our Free Plans just got better! | Auth0 by Okta

With up to 25k MAUs and unlimited Okta connections, our Free Plan lets you focus on what you do best—building great apps.

You asked, we delivered! Auth0 is excited to expand our Free and Paid plans to include more options so you can focus on building, deploying, and scaling applications without having to worry about your secuirty. Auth0 now, thank yourself later.
Try free now
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Linguist!

Additional Project Details

Operating Systems

Linux, Mac

Programming Language

Ruby

Related Categories

Ruby Graphics Software, Ruby Libraries

Registered

2021-06-29