【发布时间】:2020-10-27 16:40:43
【问题描述】:
为了检查我的包的代码质量,我正在使用包lintr 使用命令
lintr::lint_package()
得到一个我想忽略的结果:
函数的圈复杂度应小于 15
如何忽略单个 lintr 的单个“误报”lintr 结果 (cyclocomp_linter)
对于文件(行号范围)?
编辑 1: 目前我正在使用此 .lintr 配置文件作为解决方法(通过完全禁用 lintr):
linters: with_defaults(
cyclocomp_linter = NULL # instead of NULL I could use: cyclocomp_linter(16)
)
【问题讨论】: