我使用brew安装了cloc。
我喜欢检查Django项目的代码行数。
我绝对不想计算迁移中的那些,只限于python文件。
我在项目根目录下尝试了cloc --not-match-d=migrations --include-lang=python .和cloc --not-match-d=migrations --include-lang=py .,但它们都被忽略了。
这就是结果:
± cloc --not-match-d=migrations --include-lang=python .
18714 text files.
13100 unique files.
18771 files ignored.发布于 2021-06-25 23:36:09
你快到了..。语言名称区分大小写。这应该是可行的
cloc --not-match-d=migrations --include-lang=Python .语言名称必须与cloc --show-lang条目之一匹配。如果名称中有空格,请用引号将其括起来,例如--include-lang="Visual Basic"。
https://stackoverflow.com/questions/68124744
复制相似问题