This repository was archived by the owner on Jul 19, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,11 @@ duplication, try raising the threshold. If you suspect that the engine isn't
44
44
catching enough duplication, try lowering the threshold. The best setting tends
45
45
to differ from language to language.
46
46
47
- To adjust this setting, add a ` mass_threshold` key with your preferred value for
47
+ You can set thresholds for the two different types of duplication this engine
48
+ reports: blocks that are identical to each other, and blocks that are
49
+ structurally similar but differ in content.
50
+
51
+ To adjust these thresholds, you can add ` identical_mass_threshold` and `similar_mass_threshold` keys with your preferred value for
48
52
an enabled language :
49
53
50
54
` ` ` yaml
@@ -54,11 +58,15 @@ engines:
54
58
config:
55
59
languages:
56
60
ruby:
57
- mass_threshold: 20
61
+ identical_mass_threshold: 20
62
+ similar_mass_threshold: 30
58
63
javascript:
59
64
` ` `
60
65
61
- Note that you have the update the YAML structure under the `langauges` key to
66
+ If you would like to use the same threshold for both identical & similar issues,
67
+ you can just set the `mass_threshold` key.
68
+
69
+ Note that you have to update the YAML structure under the `langauges` key to
62
70
the Hash type to support extra configuration.
63
71
64
72
[codeclimate] : https://codeclimate.com/dashboard
You can’t perform that action at this time.
0 commit comments