Skip to content

Commit

Permalink
chore: update mago configuration to match latest release (#503)
Browse files Browse the repository at this point in the history
Signed-off-by: azjezz <azjezz@protonmail.com>
  • Loading branch information
azjezz authored Jan 23, 2025
1 parent c0c4bb6 commit 6d8685c
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 4 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@

# phpunit cache
/config/.phpunit.result.cache

# mago binary
mago
36 changes: 32 additions & 4 deletions mago.toml
Original file line number Diff line number Diff line change
@@ -1,15 +1,43 @@
[source]
paths = ["src", "tests", "examples"]
includes = ["vendor"]
excludes = []
excludes = [
"src/bootstrap.php",
"src/preload.php",
"src/Psl/Internal/Loader.php",
]

[format]
null_type_hint = "pipe"

[linter]
level = "Error"
default_plugins = true
plugins = ["phpunit"]
plugins = ["php-unit"]

[[linter.rules]]
name = "maintainability/cyclomatic-complexity"
threshold = 43

[[linter.rules]]
name = "maintainability/kan-defect"
threshold = 3.5

[[linter.rules]]
name = "maintainability/halstead"
effort_threshold = 16_000.0
volume_threshold = 1_400.0
difficulty_threshold = 18.5

[[linter.rules]]
name = "maintainability/excessive-parameter-list"
threshold = 9

[[linter.rules]]
name = "maintainability/too-many-enum-cases"
threshold = 800

[[linter.rules]]
name = "maintainability/too-many-methods"
threshold = 43

[[linter.rules]]
name = "best-practices/disallowed-functions"
Expand Down

0 comments on commit 6d8685c

Please sign in to comment.