安装
sudo apt-get install cloc # Debian, Ubuntu
brew install cloc # Mac OS X with Homebrew
choco install cloc # Windows with Chocolatey
使用
进入项目目录,然后执行如下命令:
lu@lu-Z87-HD3:~$ cloc .
67 text files.
67 unique files.
4 files ignored.
github.com/AlDanial/cloc v 1.76 T=1.02 s (62.6 files/s, 12778.9 lines/s)
-------------------------------------------------------------------------------
Language files blank comment code
-------------------------------------------------------------------------------
Go 54 2018 1118 9463
Markdown 2 92 0 229
Bourne Shell 6 43 29 68
JSON 2 0 0 11
-------------------------------------------------------------------------------
SUM: 64 2153 1147 9771
-------------------------------------------------------------------------------
网友评论