Skip to content

Commit dd4b654

Browse files
committed
Entrypoint provider for Doctrine
1 parent e019b4c commit dd4b654

File tree

7 files changed

+3006
-1544
lines changed

7 files changed

+3006
-1544
lines changed

Diff for: README.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,11 @@ includes:
1919
## Configuration:
2020
- All entrypoints of your code (controllers, consumers, commands, ...) need to be known to the detector to get proper results
2121
- By default, all overridden methods which declaration originates inside vendor are considered entrypoints
22-
- Also, there are some basic entrypoint providers for `symfony` and `phpunit`
23-
- For everything else, you can implement your own entrypoint provider, just tag it with `shipmonk.deadCode.entrypointProvider`
22+
- Also, there are some built-in providers for some magic calls that occur in `doctrine`, `symfony` and `phpunit`
23+
- For everything else, you can implement your own entrypoint provider, just tag it with `shipmonk.deadCode.entrypointProvider` and implement `ShipMonk\PHPStan\DeadCode\Provider\EntrypointProvider`
2424

2525
```neon
26+
# phpstan.neon.dist
2627
parameters:
2728
shipmonkDeadCode:
2829
entrypoints:
@@ -32,6 +33,8 @@ parameters:
3233
enabled: true
3334
phpunit:
3435
enabled: true
36+
doctrine:
37+
enabled: true
3538
3639
services:
3740
-

Diff for: composer.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
"phpstan/phpstan": "^1.11.0"
1717
},
1818
"require-dev": {
19+
"doctrine/orm": "^2.19 || ^3.0",
1920
"editorconfig-checker/editorconfig-checker": "^10.3.0",
2021
"ergebnis/composer-normalize": "^2.28",
2122
"phpstan/phpstan-phpunit": "^1.1.1",
@@ -24,7 +25,7 @@
2425
"shipmonk/composer-dependency-analyser": "^1.6",
2526
"shipmonk/name-collision-detector": "^2.0.0",
2627
"shipmonk/phpstan-rules": "^3.1",
27-
"slevomat/coding-standard": "^8.0.1",
28+
"slevomat/coding-standard": "^8.15.0",
2829
"symfony/contracts": "^2.5 || ^3.0",
2930
"symfony/event-dispatcher": "^5.4 || ^6.0 || ^7.0",
3031
"symfony/routing": "^5.4 || ^6.0 || ^7.0"

0 commit comments

Comments
 (0)