Documentation

Alternatives to popular CLI tools: cloc

Last Updated on June 4, 2023

This article spotlights alternative tools to cloc.

Man page for cloc

The software featured here is free and open source. All tools provide a command-line interface (CLI) unless otherwise stated.

Alternatives to cloc
TokeiDisplays statistics about your code
sccFast accurate code counter with complexity calculations and COCOMO estimates
SLOCCountSet of tools for counting physical Source Lines of Code
goclocA compact fast cloc tool seeking inspiration from Tokei
loccountRe-implementation of David A. Wheeler’s sloccount tool in Go
locRust implementation of cloc, but it’s more than 100x faster
tcountCount your code by tokens and patterns in the syntax tree
slocSimple tool to count source lines of code written in CoffeeScript
polyglotCommand-line tool that determines project contents
enryProgramming language detector based on go-enry
LinguistAssess a repository’s languages stats with github-linguist executable
Have we missed any open source alternatives to cloc? Please let us know!
4
Alternatives to clocx

All the CLI tools in this series.

Alternatives to CLI tools
age // awk // bc // cal // cat // cd // chmod // cksum // cloc // cmp // compress // cp // cron // curl // cut // date // dd // df // diff // dig // du // fdisk // find // ftp // grep // gzip // hexdump // history // jq // kill // less // locate // ls // lsof // make // man // more // mv / ping // ps // psql // rename // rm // sed // split // ssh // strings // sudo // sysctl // tail // talk // tar // telnet // time // top // touch // traceroute // tree // uname // uniq // uptime // vi // watch // Wget // who // whois // xargs

Best Free and Open Source SoftwareRead our complete collection of recommended free and open source software. Our curated compilation covers all categories of software.

The software collection forms part of our series of informative articles for Linux enthusiasts. There are hundreds of in-depth reviews, open source alternatives to proprietary software from large corporations like Google, Microsoft, Apple, Adobe, IBM, Cisco, Oracle, and Autodesk.

There are also fun things to try, hardware, free programming books and tutorials, and much more.
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Please read our FAQ before making a comment.

12 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Chris T
Chris T
1 year ago
Have we missed any open source alternatives to cloc? Please let us know!" Read more »

I suggest adding gocloc, it’s written in Go.

Norm
Norm
1 year ago
Reply to  Chris T

I see what they did there…

Penny
Penny
1 year ago
Have we missed any open source alternatives to cloc? Please let us know!" Read more »

I’m using loccount, it’s a reimplementation of sloccount.

Captain Caveman
Captain Caveman
1 year ago

It’s interesting how some of these projects claim they are the fastest with examples to back up their assertion, even though they make contradictory claims.

Ivan the awful
Ivan the awful
1 year ago
Have we missed any open source alternatives to cloc? Please let us know!" Read more »

You missed out tcount. Step up guys!

Jordan
Jordan
1 year ago
Have we missed any open source alternatives to cloc? Please let us know!" Read more »

There’s the CoffeeScript sloc tool, and polygot which is written in ATS.

Keep up the good work!