是否有工具或代码片段可以以某种形式生成以下输出:
lines_of_code = 98
lines_of_comments = 24
lines_of_documentation = 11
注 1:然后我将尝试将此数据提供给 Jenkins绘制图表。
注 2:我知道 CLOC计算评论,但我想单独计算评论和文档字符串。
最佳答案
查看 PyLint:http://www.logilab.org/857
关于python - 如何计算 Python 模块的代码行、注释和文档字符串?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5590286/