python - 在 python 上使用 cpd

标签 python cpd

我试图在我的 python 代码库上运行 CPD 的 GUI 版本,但即使我将最小块大小设置为 1,也没有返回重复代码。

我的代码不是那么好。

有没有人在 python 项目上成功运行 CPD?

最佳答案

自 PMD v5.3.0(2015 年 1 月)起原生支持 Python:https://pmd.github.io/latest/pmd-python/index.html 它可以像这样运行:

.\cpd.bat --minimum-tokens 75 --files C:\Path\to\your\project\ --language python

关于python - 在 python 上使用 cpd,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6697809/

相关文章:

python - 拆分数据时使用 scikit-learn 规范化 PCA

maven - PMD/CPD 无法检测重复代码

c++ - 抑制来自 CPD 的 C/C++ 代码警告

sonarqube - Sonarqube 的 CPD 是什么?

java - PMD CPD 排除 equals 和 hashcode 等方法?

python - Boto3 ec2 describe_instances 始终返回空

python - 如何使用 python 在 Windows 中关闭文件资源管理器

python - 如何在同一个Python程序中监听HTTP请求和串行 channel ?

maven - 智能理念 : terminal window: making a filepath/file clickable

已经注册的类的Python boost to-Python转换器被忽略第二个转换方法