Skip to content

Instantly share code, notes, and snippets.

@XcqRomance
Created June 8, 2019 05:10
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save XcqRomance/47a5ac7001f4cb5c5f88b5deadbcbbba to your computer and use it in GitHub Desktop.
Save XcqRomance/47a5ac7001f4cb5c5f88b5deadbcbbba to your computer and use it in GitHub Desktop.
.oclint oclint进行codereview的规则配置文件
rule-configurations:
- key: CYCLOMATIC_COMPLEXITY # Cyclomatic complexity of a method 10
value: 30
- key: LONG_LINE
value: 110
- key: NCSS_METHOD # Number of non-commenting source statements of a method 30
value: 50
- key: LONG_VARIABLE_NAME
value: 40
- key: NESTED_BLOCK_DEPTH
value: 6
- key: MINIMUM_CASES_IN_SWITCH
value: 2
- key: SHORT_VARIABLE_NAME
value: 1
- key: TOO_MANY_METHODS
value: 50
- key: LONG_METHOD
value: 100
disable-rules:
- RedundantLocalVariable
- SHORT_VARIABLE_NAME
- LongVariableName
- UnnecessaryElseStatement
- RedundantNilCheck
- RedundantIfStatement
- InvertedLogic
- AssignIvarOutsideAccessors
- UseObjectSubscripting
- BitwiseOperatorInConditional
- PreferEarlyExit
- UnusedMethodParameter
max-priority-1: 1000
max-priority-2: 1000
max-priority-3: 1000
enable-clang-static-analyzer: false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment