PHPackages                             elvanto/referee - 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. elvanto/referee

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

elvanto/referee
===============

A simple tool for refactoring legacy PHP code

0.0.1(10y ago)14281MITPHP

Since May 13Pushed 7y ago4 watchersCompare

[ Source](https://github.com/elvanto/referee)[ Packagist](https://packagist.org/packages/elvanto/referee)[ RSS](/packages/elvanto-referee/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (4)Versions (4)Used By (0)

Referee
=======

[](#referee)

Referee is a simple tool for refactoring legacy PHP code, based on the strategies presented in Paul M. Jones' book [Modernizing Legacy Applications in PHP](https://leanpub.com/mlaphp).

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

[](#installation)

The preferred installation method is [composer](https://getcomposer.org);

```
composer require-dev elvanto/referee
```

Usage
-----

[](#usage)

A list of valid commands can be found by running `vendor/bin/referee list`. Before executing any of the commands, it is recommended that you are using a version control system with a clean working copy. This will ensure that any unwanted changes can be rolled back without affecting prior changes.

Using the `--dry-run` flag with any of the commands will result in changes being reported without any files being updated.

### Extracting static classes from function files

[](#extracting-static-classes-from-function-files)

The `extract-class` command takes the name of a file containing function definitions and generates a namespaced class with equivalent static methods. Any usages of the original functions in the `` directories will be replaced with appropriate static method calls on the newly generated class. All files are changed in place.

Further commands will be added in future.

License
-------

[](#license)

[MIT License](LICENSE)

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

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

Unknown

Total

1

Last Release

3686d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/77a936b5c659456479744d404f68ba7bca9552f1d008aa2cf3b8a9175c9ddfb4?d=identicon)[bensinclair](/maintainers/bensinclair)

![](https://www.gravatar.com/avatar/7cf1c2feb7af5eafbcec1d7258f9909e785bb27bda7ca57e47a2794241bf960c?d=identicon)[joshmcrae](/maintainers/joshmcrae)

---

Top Contributors

[![joshmcrae](https://avatars.githubusercontent.com/u/12324115?v=4)](https://github.com/joshmcrae "joshmcrae (7 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/elvanto-referee/health.svg)

```
[![Health](https://phpackages.com/badges/elvanto-referee/health.svg)](https://phpackages.com/packages/elvanto-referee)
```

###  Alternatives

[friendsoftypo3/content-blocks

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

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

Composer helps you declare, manage and install dependencies of PHP projects. It ensures you have the right stack everywhere.

29.5k196.2M3.1k](/packages/composer-composer)[friendsofphp/php-cs-fixer

A tool to automatically fix PHP code style

13.5k251.2M25.2k](/packages/friendsofphp-php-cs-fixer)[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)
