This repository has been archived by the owner on Jun 6, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
analysis_options.yaml
67 lines (64 loc) · 2.34 KB
/
analysis_options.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
analyzer:
language:
strict-inference: true
strict-raw-types: true
# Dart Code Metrics uses plugins api from the analyzer
# to provide issues highlight in the IDE. If you don't want the issues
# to be shown and need only the CLI, you need to remove the section below.
plugins:
- dart_code_metrics
strong-mode:
implicit-casts: false
implicit-dynamic: false
dart_code_metrics:
# Dart Code Metrics supports presets. The config from a preset will be merged
# with the config listed in this file. The config listed here has a higher priority.
# Any rule can be simply disabled by setting `- rule-name: false`.
# Uncomment the section below to see how presets work.
# extends:
# - package:dart_code_metrics/presets/all.yaml
# To enabled anti-patterns and metrics in the analysis report, uncomment the sections below.
# Metric violations are not shown in the IDE.
# anti-patterns:
# - long-method
# - long-parameter-list
# metrics:
# cyclomatic-complexity: 20
# maintainability-index: 50
# maximum-nesting: 5
# number-of-parameters: 5
# source-lines-of-code: 50
# technical-debt:
# threshold: 16
# todo-cost: 4
# ignore-cost: 8
# ignore-for-file-cost: 16
# as-dynamic-cost: 16
# deprecated-annotations-cost: 2
# file-nullsafety-migration-cost: 2
# unit-type: "hours"
# Dart Code Metics provides custom configurable rules.
# The rules have a `kebab-case` naming instead of
# `snake_case` intentionally in order for you to identify,
# whether the rule is from Dart Code Metrics or the standard analyzer.
# All rules share basic configuration like `exclude` section,
# but some also have a rule-specific one.
# Not all rules are listed here, the full list can be found on our website: https://dartcodemetrics.dev/docs/rules
rules:
- avoid-top-level-members-in-tests
- avoid-collection-methods-with-unrelated-types
- avoid-missing-enum-constant-in-map
- avoid-unnecessary-type-assertions
- avoid-unnecessary-type-casts
- avoid-unused-parameters
- newline-before-return
- no-boolean-literal-compare
- no-empty-block
- no-equal-then-else
- prefer-async-await
- prefer-correct-type-name:
max-length: 44
- prefer-match-file-name:
exclude:
- test/**
- prefer-trailing-comma