PHPackages                             akeneo/php-coupling-detector - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. akeneo/php-coupling-detector

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

akeneo/php-coupling-detector
============================

Detect all the coupling issues of your project with respect to the coupling rules you have defined.

v0.8.3(1y ago)431.1M↑169.8%5[18 issues](https://github.com/akeneo/php-coupling-detector/issues)3MITPHPPHP ^7.2||^8.0CI failing

Since Mar 29Pushed 1y ago33 watchersCompare

[ Source](https://github.com/akeneo/php-coupling-detector)[ Packagist](https://packagist.org/packages/akeneo/php-coupling-detector)[ RSS](/packages/akeneo-php-coupling-detector/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (10)Dependencies (7)Versions (14)Used By (3)

PHP Coupling Detector
=====================

[](#php-coupling-detector)

The PHP Coupling Detector tool detects all the coupling issues of your project with respect to the coupling rules you have defined.

At the moment, only PHP coupling issues are detected by analysing the use statements of the classes in your project. But adding a new kind of coupling detections is doable in the future. We could for example imagine to detect the coupling issues of Symfony services that are defined in YAML or XML

At the moment, 3 types of rules are supported:

- *forbidden*: A node respects such a rule if no rule token is present in the node. In case the node does not respect this rule, an error violation will be sent.
- *discouraged*: A node respects such a rule if no rule token is present in the node. In case the node does not respect this rule, a warning violation will be sent.
- *only*: A node respects such a rule if the node contains only tokens defined in the rule. In case the node does not respect this rule, an error violation will be sent.

Requirements
------------

[](#requirements)

PHP needs to be a minimum version of PHP 7.2

Installation
------------

[](#installation)

```
    $ composer require akeneo/php-coupling-detector
```

Usage
-----

[](#usage)

To discover how to use this tool, please read the usage of the [detect](doc/DETECT.md) and [list-unused-requirements](doc/LIST_UNUSED_REQUIREMENTS.md) commands.

Development
-----------

[](#development)

You can develop out of the box thanks to the provided `docker-compose.yml` and `Makefile` files

To install the app:

```
    $ make install
    $ make vendor
```

To launch tests on your machine:

```
    $ make test
```

###  Health Score

46

—

FairBetter than 92% of packages

Maintenance31

Infrequent updates — may be unmaintained

Popularity48

Moderate usage in the ecosystem

Community30

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~268 days

Recently: every ~278 days

Total

13

Last Release

526d ago

PHP version history (6 changes)0.1.0PHP &gt;=5.3.6

0.3.0PHP ^7.1

v0.5.0PHP ^7.2

v0.6.0PHP &gt;=7.2

v0.7.1PHP ^7.2||8.0.\*

v0.8.0PHP ^7.2||^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/0cef3bd3ee7dbc7de6b5e8ec623f0410578b1e3cbca5e5aaf0e2b7f5d5f8ccbb?d=identicon)[nidup](/maintainers/nidup)

---

Top Contributors

[![jjanvier](https://avatars.githubusercontent.com/u/3691804?v=4)](https://github.com/jjanvier "jjanvier (72 commits)")[![nidup](https://avatars.githubusercontent.com/u/2104359?v=4)](https://github.com/nidup "nidup (54 commits)")[![damien-carcel](https://avatars.githubusercontent.com/u/5039018?v=4)](https://github.com/damien-carcel "damien-carcel (9 commits)")[![AymericPlanche](https://avatars.githubusercontent.com/u/927944?v=4)](https://github.com/AymericPlanche "AymericPlanche (5 commits)")[![MathChevalier](https://avatars.githubusercontent.com/u/103497303?v=4)](https://github.com/MathChevalier "MathChevalier (5 commits)")[![phaseinducer](https://avatars.githubusercontent.com/u/659491?v=4)](https://github.com/phaseinducer "phaseinducer (4 commits)")[![pierallard](https://avatars.githubusercontent.com/u/1590933?v=4)](https://github.com/pierallard "pierallard (3 commits)")[![jmleroux](https://avatars.githubusercontent.com/u/1516770?v=4)](https://github.com/jmleroux "jmleroux (3 commits)")[![Beninho](https://avatars.githubusercontent.com/u/1288342?v=4)](https://github.com/Beninho "Beninho (2 commits)")[![Seldaek](https://avatars.githubusercontent.com/u/183678?v=4)](https://github.com/Seldaek "Seldaek (1 commits)")[![gplanchat](https://avatars.githubusercontent.com/u/152367?v=4)](https://github.com/gplanchat "gplanchat (1 commits)")[![Nyholm](https://avatars.githubusercontent.com/u/1275206?v=4)](https://github.com/Nyholm "Nyholm (1 commits)")[![anaelChardan](https://avatars.githubusercontent.com/u/6115681?v=4)](https://github.com/anaelChardan "anaelChardan (1 commits)")

###  Code Quality

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/akeneo-php-coupling-detector/health.svg)

```
[![Health](https://phpackages.com/badges/akeneo-php-coupling-detector/health.svg)](https://phpackages.com/packages/akeneo-php-coupling-detector)
```

###  Alternatives

[friendsofphp/php-cs-fixer

A tool to automatically fix PHP code style

13.5k251.2M25.2k](/packages/friendsofphp-php-cs-fixer)[symfony/framework-bundle

Provides a tight integration between Symfony components and the Symfony full-stack framework

3.6k251.7M11.6k](/packages/symfony-framework-bundle)[friendsoftypo3/content-blocks

TYPO3 CMS Content Blocks - Content Types API | Define reusable components via YAML

103519.9k53](/packages/friendsoftypo3-content-blocks)[drupal/core

Drupal is an open source content management platform powering millions of websites and applications.

21866.0M1.7k](/packages/drupal-core)[drupal/core-recommended

Locked core dependencies; require this project INSTEAD OF drupal/core.

6942.5M421](/packages/drupal-core-recommended)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.6M574](/packages/shopware-core)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
