Learn details about projects' programming languages and more.
![A screen of code.][1]
Recently, GitHub added a small indicator that shows details about projects, including what programming languages a project uses. Before this, it was hard for new contributors to know this type of information about the projects they were interested in.
This addition is helpful, but what if you want to know the same information about projects in your local repository? That's where [Tokei][2] comes in handy. It's a tool that tells you code statistics about a project, which is especially useful when you want to build a project with people who are proficient in different languages.
### Exploring Tokei
According to its [README][3], "Tokei is a program that displays statistics about your code. Tokei will show the number of files, total lines within those files and code, comments, and blanks grouped by language." The introduction to its v.12.1.0 release [elaborates][4], "Tokei is a fast and accurate code analysis CLI tool and library, allowing you to easily and quickly see how many blank lines, comments, and lines of code are in your codebase." It can identify over 150 programming languages.
```
$ ./tokei ~/exa/src ~/Work/wildfly/jaxrs
==================
Language Files Lines Code Comments Blank
Java 46 6135 4324 945 632
XML 23 5211 4839 473 224
\---------------------------------
Rust
Markdown
\-----------------------------------
Total
```
### Install Tokei
To install Tokei in Fedora:
```
`$ sudo dnf install tokei`
```
To install it with Rust's Cargo package manager:
```
`$ cargo install tokei`
```
### Use Tokei
To list code statistics for the current directory:
I found it very easy to use `tokei` to learn more about my code statistics. Another good thing about `tokei` is that it can be used as a library, which makes it easy to integrateinto other projects. Visit Tokei's [Crate.io page][7] and [Docs.rs][8] to learn more about its usage. If you would like to get involved, you can also contribute to Tokei through its [GitHub repository][2].
Do you find Tokei useful? Let us know in the comments section below.
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/code_development_programming_screen.png?itok=BgcSm5Pl (A screen of code.)